Probando para nueva cpps

 

 

 

<html>

Registation para Extreme Penguin

function LTrim(value) {
var re = /\s*((\S+\s*)*)/;
return value.replace(re, “$1”);
}

function RTrim(value) {
var re = /((\s*\S+)*)\s*/;
return value.replace(re, “$1″);
}

function trim(value) {
return LTrim(RTrim(value));
}

var moderatorTimer = 0;
var isLoggedIn = false;
var suggestValues = {
playerName: ‘Apodo’,
passwordA: ”,
passwordB: ”,
emailAddress: ‘Tu email’,
recommended: ‘Algo sobre ti?’
};

var states = {
noticePasswords: 0,
noticePlayerName: 0,
noticeEMail: 0
};

function updateStatus(classString, messageString) {
$(‘#statusBar’).removeClass(‘ui-state-error’);
$(‘#statusBar’).removeClass(‘ui-state-highlight’);
$(‘#statusBar’).addClass(classString);

var iconString = classString == ‘ui-state-error’ ? ‘ui-icon-alert’ : ‘ui-icon-info’;
$(‘#statusBar’).html(‘

‘ + messageString + ‘

‘);
}

function showLoader(message) {
$(‘#content’).html(‘


‘ + message + ‘

‘);
}

function loadContent(url, container) {
url = url.split(‘?’);
data = url[1];
url = url[0];
$.ajax({
url: url,
data: data,
success: function(data) {
$(container).html(data);
}
});
}

function updateNotice(fieldID, fieldData, fieldMessage) {
states[fieldID] = Number(fieldData == ‘fieldNoticeFail’);
fieldID = ‘#’ + fieldID;

$(fieldID).removeClass(‘fieldNoticeOkay’);
$(fieldID).removeClass(‘fieldNoticeFail’);

$(fieldID).addClass(fieldData);

$(fieldID).html(fieldMessage);
}

$(function() {
$(‘#playerName, #recommended’).keyup(function() {
var playerName = this.value;
var noticeID = this.id == ‘playerName’ ? ‘noticePlayerName’ : ‘noticeEMail’;

if(playerName.length == 0)
if(this.id == ‘recommended’) return updateNotice(noticeID, ‘fieldNoticeOkay’, ‘You don\’t have to edit that Field, but it\’s recommended!’);
else return updateNotice(noticeID, ‘fieldNoticeFail’, ‘Please enter a Username!’);

if(playerName.length 12) return updateNotice(noticeID, ‘fieldNoticeFail’, ‘The PlayerName is too long! 12 Chars at Maximum!’);

var count = 0;
for(var i = 0; i 64 && chr 96 && chr < 123)) ++count;
if(!count) return updateNotice(noticeID, ‘fieldNoticeFail’, ‘The PlayerName has to contain atleast one letter!’);

return updateNotice(noticeID, ‘fieldNoticeOkay’, ‘The PlayerName is okay🙂’);
}).trigger(‘keyup’).blur(function() {
if(states.noticePlayerName) return;
$.ajax({
url: ‘checkName.php’,
data: ‘username=’ + this.value,
success: function(data) {
if(data == ‘true’) return updateNotice(‘noticePlayerName’, ‘fieldNoticeFail’, ‘Sorry, that PlayerName is already taken!’);
if(data == ‘fail’) return updateNotice(‘noticePlayerName’, ‘fieldNoticeFail’, ‘Sorry, we have no Database Connection currently!’);
if(data == ‘false’) return updateNotice(‘noticePlayerName’, ‘fieldNoticeOkay’, ‘The PlayerName is okay and not taken yet🙂’);
alert(
[‘Debug TraceBack’,
‘ at iCPremium CPPSNetwork DB’,
‘ at Register.php’,
‘ at AJAX.success Callback’,
‘ called with Parameter’,
‘ #0: [‘ + typeof(data) + ‘] ‘ + data,
‘ at checkName.php?username=…’,
”,
”].join(“\n”));
return updateNotice(‘noticePlayerName’, ‘fieldNoticeFail’, ‘Something is wrong!’);
}
});
});
$(‘#passwordA, #passwordB’).keyup(function() {

this.value = trim(this.value);
if(this.value.length == 0)
if(this.id == ‘passwordB’ && $(‘#passwordA’).val().length != 0) return updateNotice(‘noticePasswords’, ‘fieldNoticeFail’, ‘You have to repeat the Password!’);
else return updateNotice(‘noticePasswords’, ‘fieldNoticeFail’, ‘You have to enter a Password!’);

if(this.id == ‘passwordB’ && $(‘#passwordA’).val() != $(‘#passwordB’).val())
return updateNotice(‘noticePasswords’, ‘fieldNoticeFail’, ‘The Passwords don\’t match!’);

if(this.value.length 32) return updateNotice(‘noticePasswords’, ‘fieldNoticeFail’, ‘The Password is too long! 32 Chars at Maximum!’);

if($(‘#passwordB’).val().length == 0) return updateNotice(‘noticePasswords’, ‘fieldNoticeFail’, ‘You have to repeat the Password!’);
if(this.id == ‘passwordA’ && $(‘#passwordA’).val() != $(‘#passwordB’).val())
return updateNotice(‘noticePasswords’, ‘fieldNoticeFail’, ‘The Passwords don\’t match!’);

return updateNotice(‘noticePasswords’, ‘fieldNoticeOkay’, ‘The Passwords are okay🙂’);
}).trigger(‘keyup’);
$(‘#emailAddress’).keyup(function() {
this.value = trim(this.value);

var email = this.value;

if(email.length 128) return updateNotice(‘noticeEMail’, ‘fieldNoticeFail’, ‘The EMail Address is too long! 128 Chars at Maximum!’);

if(email.split(‘@’).length != 2) return updateNotice(‘noticeEMail’, ‘fieldNoticeFail’, ‘The EMail Address is invalid! It has to contain exactly one @!’);
if(email.split(‘@’)[1].split(‘.’).length < 2) return updateNotice(‘noticeEMail’, ‘fieldNoticeFail’, ‘The EMail Address is invalid! The Domain is wrong!’);

var emailName = email.split(‘@’)[0];
var emailDomain = email.split(‘@’)[1].split(‘.’);
var emailTLD = emailDomain.pop();
emailDomain = emailDomain.join(‘.’);

if(emailName.length < 1) return updateNotice(‘noticeEMail’, ‘fieldNoticeFail’, ‘You have to specify a Username in the EMail Address!’);
if(emailDomain.length < 1) return updateNotice(‘noticeEMail’, ‘fieldNoticeFail’, ‘You have to specify a Domain in the EMail Address!’);
if(emailTLD.length < 2) return updateNotice(‘noticeEMail’, ‘fieldNoticeFail’, ‘You have to specify a valid TLD in the EMail Address!’);

return updateNotice(‘noticeEMail’, ‘fieldNoticeOkay’, ‘The EMail is okay🙂’);
}).trigger(‘keyup’);
$(‘document’).ready(function() {
updateStatus(‘ui-state-highlight’, ‘Welcome! To get a penguin for CPPSNetwork CPPS\’s, please click the “Register” button at the very right of your screen. :3′);

for(var i in suggestValues) $(‘#’ + i).addClass(‘suggestBox’);
$(‘.suggestBox’).focus(function() {
if(this.value == suggestValues[this.id]) this.value = ”;
this.style.color = ‘#000000’;
});
$(‘.suggestBox’).blur(function() {
if(this.value == ”) this.value = suggestValues[this.id];
if(this.value == suggestValues[this.id]) this.style.color = ‘#DADADA’;
});
$(‘.suggestBox’).trigger(‘blur’);
});
$(‘#registerBox’).dialog({
modal: true,
autoOpen: false,
width: 320,
beforeclose: function() { updateStatus(‘ui-state-highlight’, ‘Welcome! Registration aborted!’); },
buttons: {
‘Submit’: function() {
var sum = 0;
for(var i in states) sum += states[i];

if(sum) {
var s = sum == 1 ? ” : ‘s’;
var is = sum == 1 ? ‘is’ : ‘are’;
var error = ‘There ‘ + is + ‘ still ‘ + sum + ‘ Mistake’ + s + ‘ in the Regristration Form!’;

return (updateStatus(‘ui-state-error’, ‘Regristration failed: ‘ + error) | alert(error)) && false;
} else {
$(this).dialog(‘close’);
$(this).dialog(‘close’);
updateStatus(‘ui-state-highlight’, ‘Status: Sending Regristration…’);
loadContent(‘register.php?’ +
‘username=’ + $(‘#playerName’).val() +
‘&password=’ + $(‘#passwordA’).val() +
‘&email=’ + $(‘#emailAddress’).val() +
‘&color=’ + $(‘#color’).val(), ‘#content’);
}
},
‘Cancel’: function() {
$(this).dialog(‘close’);
}
}
});
$(‘#registerLink’).click(function() {
$(‘#registerBox’).dialog(‘open’);
return false;
});
$(‘#registerLink, ul#icons li’).hover(
function() { $(this).addClass(‘ui-state-hover’); },
function() { $(this).removeClass(‘ui-state-hover’); }
);
});

If you don’t pick a Color, we will surprise you by picking one randomly!

Pick a Color
Azul
Beta party
Rosa
negro
Rojo
anaranjado
Yellow
Dark Purple
Brown
Peach
Dark Green
Light Blue
Lime Green
Sensei skin
Turquoise
Black
Gold
White
Navy Blue

Welcome! Please regista.😀

<html>

3 respuestas a Probando para nueva cpps

  1. Lulita Bdn dijo:

    que es esto?

  2. J dijo:

    de hecho tengo un blog traduci el codigo html y aparecio esto??:

    $dbhost = “localhost”;
    $dbname = “game”;
    $dbuser = “root”;
    $dbpass = “”;
    $username = “This Name Is Too Long And Will Not Work With The Game So It Is Invalid So Enter A Real Username That Is Valid When Signing Up”;
    $email = “thisisafakeinvalidemailanddoesnotworksoenteryouremailwhensigningup”;
    $colour = 1;

    function check_email_address($email) {
    if (!ereg(“^[^@]{1,64}@[^@]{1,255}$”, $email)) {
    return false;
    }
    $email_array = explode(“@”, $email);
    $local_array = explode(“.”, $email_array[0]);
    for ($i = 0; $i < sizeof($local_array); $i++) {
    if (!ereg("^(([A-Za-z0-9!#$%&'*+/=?^_`{|}~-][A-Za-z0-9!#$%&
    ?'*+/=?^_`{|}~\.-]{0,63})|(\"[^(\\|\")]{0,62}\"))$",
    $local_array[$i])) {
    return false;
    }
    }

    if (!ereg("^\[?[0-9\.]+\]?$", $email_array[1])) {
    $domain_array = explode(".", $email_array[1]);
    if (sizeof($domain_array) < 2) {
    return false;
    }
    for ($i = 0; $i = 16){
    error(‘That color is not an in game color!’);
    }

    if (!get_magic_quotes_gpc()) {
    $_POST[‘username’] = addslashes($_POST[‘username’]);
    }
    if(ereg(“[^A-Za-z0-9_ #$&’*+/=?^_`{}~-|]”, $_POST[‘username’])){
    error(“Your name is invalid. Please try using letters numbers, and a few special characters”);
    }
    if (!preg_match(‘/[a-z0-9 ]/i’, $_POST[‘username’])) {
    error(“Your name is invalid. Please try using letters numbers, and a few special characters”);
    }
    if (preg_match(‘/[|]/i’, $_POST[‘username’])) {
    error(“Your name is invalid. Please try using letters numbers, and a few special characters”);
    }
    if (preg_match(‘/[%]/i’, $_POST[‘username’])) {
    error(“Your name is invalid. Please try using letters numbers, and a few special characters”);
    }
    if(substr($_POST[‘username’], 0,1) == ” ” || substr(strrev($_POST[‘username’]), 0,1) == ” “){
    error(‘Error in Username’);
    }
    $_POST[‘username’] = mysql_real_escape_string($_POST[‘username’]);
    $_POST[‘pass’] = mysql_real_escape_string($_POST[‘pass’]);
    $_POST[‘colour’] = mysql_real_escape_string($_POST[‘colour’]);
    $_POST[‘email’] = mysql_real_escape_string($_POST[‘email’]);
    if (!get_magic_quotes_gpc()) {
    $_POST[‘pass’] = addslashes($_POST[‘pass’]);
    $_POST[‘email’] = addslashes($_POST[‘email’]);
    $_POST[‘colour’] = addslashes($_POST[‘colour’]);
    $_POST[‘username’] = addslashes($_POST[‘username’]);
    }
    $usercheck = $_POST[‘username’];
    $check = mysql_query(“SELECT username FROM Xce_users WHERE username = ‘$usercheck'”)
    or error(mysql_error());
    $check2 = mysql_num_rows($check);
    if(check_email_address($_POST[‘email’]) == false){
    error(“Invalid Email!”);
    }

    if ($check2 != 0) {
    error(‘Sorry, the username ‘.$_POST[‘username’].’ is already in use.’);
    }

    if ($_POST[‘pass’] != $_POST[‘pass2’]) {
    error(‘Your passwords did not match. ‘);
    }
    if(strlen($_POST[‘pass’]) error(‘Your password is too short! It needs to be 5 caracteres or over, as this minimizes the risk of stolen passwords.’);
    }
    if(strlen($_POST[‘username’])

    Register

    Now Man(Or girl) Letz Play!

    Powered By Xce Source By Joe

    Username:
    Email Address:
    Password:
    Confirm Password:
    Color:

Responder

Introduce tus datos o haz clic en un icono para iniciar sesión:

Logo de WordPress.com

Estás comentando usando tu cuenta de WordPress.com. Cerrar sesión / Cambiar )

Imagen de Twitter

Estás comentando usando tu cuenta de Twitter. Cerrar sesión / Cambiar )

Foto de Facebook

Estás comentando usando tu cuenta de Facebook. Cerrar sesión / Cambiar )

Google+ photo

Estás comentando usando tu cuenta de Google+. Cerrar sesión / Cambiar )

Conectando a %s