View Single Post
Old 01-17-2012, 09:09 AM   PM User | #1
toplisek
Regular Coder

 
Join Date: May 2006
Posts: 205
Thanks: 4
Thanked 0 Times in 0 Posts
toplisek has a little shameless behaviour in the past
Question How to set session based Hide/show message notice?

I have set Javascript function to Expand or Collapse my messages.

PHP Code:


<div onclick="javascript:js_message.expcollap();" style="">&nbsp;</div>

<
button id="show">Show</button>


<
script language="JavaScript" type="text/javascript">
/*<![CDATA[*/
var js_message = {expcollap:function () {$("#message_notice").click(function(){$("div").hide(1000);});$("#show").click(function(){$("div").show();});
}}
/*]]>*/
</script> 
How to set session value that user will see this message only once even he visits page twice (back button or click on the same URL).
toplisek is offline   Reply With Quote