Location: PHPKode > projects > Serveur Multicartes IPX800 > multicardipx800/js/js.function.php
<?php
    $GLOBALS["root_path"] = "../";
    require_once($GLOBALS["root_path"]."LoadConfig.php");
    session_name((string)$GLOBALS["config"]->general->namesession); 
    session_start();
    header('content-type: text/javascript' );
    echo '/*------------------------------------------------------------------------------'."\n";
    echo 'Script : '.$_SERVER['PHP_SELF']."\n";
    $skin=$GLOBALS["config"]->general->skin;
    echo 'Skin courante : '.$skin."\n"; 
    echo '------------------------------------------------------------------------------*/'."\n";
?>
function UpdateTitle(Message)
{
	if ( document.getElementById('Title') ) 
	{
		document.getElementById('Title').innerHTML = Message;
	}
}

function UpdateMessage(Message)
{
	if ( document.getElementById('StatusMsg') ) 
	{
		document.getElementById('StatusMsg').innerHTML = Message;
	}
}
 
function UpdateImage(IdObject)
{
	Object = document.getElementById(IdObject);
	if ( Object.options.selectedIndex != -1 )
		document.getElementById('preview_'+IdObject).src = '<?php echo $GLOBALS["root_path"].'images/skins/'.$skin;?>/'+Object.options[Object.options.selectedIndex].value;
}

function DonnerFocus(Id) 
{
	document.getElementById(Id).focus();
}


function UpdateMsg(Message, Type)
{
	if ( document.getElementById('Msg') ) 
	{
		if ( Message != '' )
		{
			document.getElementById('Msg').innerHTML = Message;
			document.getElementById('Msg').setAttribute("class",Type);
			document.getElementById('Msg').display = "block";
		}
		else
		{
			document.getElementById('Msg').display = "none";
		}
	}
}

function UpdateStatus(option)
{
	if ( document.getElementById('UpdateStatus') == null || document.getElementById('UpdateStatus').value == 0 )
	{
		if ( option )
			url = 'Xml.php?'+option;
		else
			url = 'Xml.php';
		GetXML('Xml.php', AjaxUpdateStatus, '', true);
	}
}

function Disp(object)
{
	if ( document.getElementById(object).style.display == 'block' )
	{
		document.getElementById(object).style.display = 'none';
	}
	else
	{
		document.getElementById(object).style.display = 'block';
	}
}

debut = new Date;
debut = debut.getTime();


function DoCheckAll(val)
{
	inputs = document.getElementsByTagName("input");
	for(var i=0;i < inputs.length;i++)
	{
		input = inputs[i];
		if ( input.type == 'checkbox' )
		{
			input.checked = val;
		}
	}
}

function HTMLEncode(wText)
{
	if(typeof(wText)!="string")
	{
		wText=wText.toString();
	}
	wText=wText.replace(/&/g, "&amp;") ;
	wText=wText.replace(/"/g, "&quot;") ;
	wText=wText.replace(/</g, "&lt;") ;
	wText=wText.replace(/>/g, "&gt;") ;
	wText=wText.replace(/'/g, "&#146;") ;
	return wText;
}
//******** end js.function.php
Return current item: Serveur Multicartes IPX800