<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<META content="MSHTML 6.00.3790.1830" name=GENERATOR></HEAD>
<BODY><INPUT id=txt> <INPUT id=btn οnclick="Session.save('txt','value','op');" type=button value=save>
<INPUT id=btn1 οnclick="alert(Session.load('op'));" type=button value=load>
<SCRIPT>
function Session()
{
var SessionObj = null;
this.init = function()
{
SessionObj = document.createElement('input');
SessionObj.type = "hidden";
SessionObj.id = "Sessionid";
SessionObj.style.behavior = "url('#default#userData')"
document.body.appendChild(SessionObj);
}
this.load = function(sessionName)
{
if (sessionName != null && sessionName != "")
{
SessionObj.load("s");
return SessionObj.getAttribute(sessionName);
}
}
this.save = function(objId,attribute,sessionName)
{
var obj = null;
if (document.getElementById(objId) != null) obj = document.getElementById(objId)
else return;
var value = obj[attribute];
if (sessionName != null && sessionName != "")
{
SessionObj.setAttribute(sessionName,value)
SessionObj.save("s")
}
}
this.init();
}
var Session = new Session();
</SCRIPT>
</BODY></HTML>