function showsuccess () {
$('successmessage').innerHTML = '
Updates Saved Successfully !
';
new Effect.Appear($('successmessage'));
new Effect.Highlight($('successmessage'), { startcolor: '#E97C24', endcolor: '#FFD3AF'});
setTimeout("new Effect.Fade($('successmessage'));", 2500);
}
function popup_submit(id) {
var parameters = $("popup-"+id).serialize();
var url = "/ajax/popup_submit.php?"+parameters;
new Ajax.Request( url, { onCreate: function(transport) {
},
onFailure: function(transport) {
$('error_'+id).innerHTML = transport.responseText;
},
onSuccess: function(transport) {
window.location = '/profile/picture.php';
}
}
);
}
function gender(v)
{
if(v=='3')
{
$('3').className="active";
$('1').className="";
$('2').className="";
}
if(v=='2')
{
$('2').className="active";
$('1').className="";
$('3').className="";
}
if(v=='1')
{
$('1').className="active";
$('2').className="";
$('3').className="";
}
}
function daychange() {
var yy = $('year').value;
var mm = $('month').value;
var url = "/ajax/personal_day_change.php?m="+mm+"&y="+yy;
new Ajax.Request( url, {
onCreate: function(transport) {
},
onFailure: function(transport) {
},
onSuccess: function(transport) {
$('day').innerHTML = transport.responseText;
}
}
);
}
function popup_daychange(id) {
var yy = $('year'+id).value;
var mm = $('month'+id).value;
var url = "/ajax/popup_day_change.php?m="+mm+"&y="+yy;
new Ajax.Request( url, {
onCreate: function(transport) {
},
onFailure: function(transport) {
},
onSuccess: function(transport) {
$('day'+id).innerHTML = transport.responseText;
}
}
);
}
function country_change() {
if($('country').value == 1) {
$('us_province').show();
$('other_province').hide();
$('province_flag').value = 1;
}
else
if($('country').value == 0) {
$('us_province').hide();
$('other_province').hide();
}
else {
$('us_province').hide();
$('other_province').show();
$('province_flag').value = 2;
}
}
function popup_country_change(id) {
if($('country-'+id).value == 1) {
$('us_province_'+id).show();
$('other_province_'+id).hide();
$('province_flag_'+id).value = 1;
}
else
if($('country-'+id).value == 0) {
$('us_province_'+id).hide();
$('other_province_'+id).hide();
}
else {
$('us_province_'+id).hide();
$('other_province_'+id).show();
$('province_flag_'+id).value = 2;
}
}
function email_check(id) {
var n = 'nickname'+id;
var email = $(n).value;
var url = "/ajax/email_check.php?email="+email;
new Ajax.Request( url, {
onCreate: function(transport) {
},
onFailure: function(transport) {
},
onSuccess: function(transport) {
$('avai'+id).innerHTML = transport.responseText;
}
}
);
}
function how_you_heard_other_fan_showhide() {
if($('how_you_heard_other_fan').value == 8)
$('how_you_heard_other_div_fan').show();
else
$('how_you_heard_other_div_fan').hide();
}
function how_you_heard_other_fighter_showhide() {
if($('how_you_heard_other_fighter').value == 8)
$('how_you_heard_other_div_fighter').show();
else
$('how_you_heard_other_div_fighter').hide();
}
function how_you_heard_other_organization_showhide() {
if($('how_you_heard_other_organization').value == 8)
$('how_you_heard_other_div_organization').show();
else
$('how_you_heard_other_div_organization').hide();
}