Select Page

Minimize some part of Your GUI to have more space

  • Let the user minimize/maximise some part of Your GUI to have more space on demand
  • Working in all browser
  •  Use cookieJar script also in this section

Method to put in Your <HEAD> html document:

var CookieJar = new TDCookieJarObj();  CookieJar.setPath("/"); function FoldByName(iImageID, sMenuID) {
if (document.getElementById(sMenuID).style.display == none) {
document.getElementById(sMenuID).style.display = block;
document.images[iImageID].src=up.gif;
document.images[iImageID].alt=Minimize;
document.images[iImageID].title=Minimize;
CookieJar.setCookie(sMenuID,"open");
} else {
document.getElementById(sMenuID).style.display = none; document.images[iImageID].src=down.gif; document.images[iImageID].alt=Maximize; document.images[iImageID].title=Maximize;
CookieJar.setCookie(sMenuID,"close");
} }

Example of use, here I want to hide the title on demand because it take a lot of space….The user has now a switch on-switch off icon where He can minimize on demand  this part of the GUI
<a href="javascript:FoldByName(‘TITLE’,’TITLE2′);"><img name=ButtonExpand id=TITLE src=down.gif alt=hide the title align=AbsMiddle style=border-width:0px; /></a> <div class=smallText id=TITLE2>
<H1> This is an Example</H1> </div> <script language=Javascript>cookie = CookieJar.getCookie("TITLE2");if ( cookie == "close" )FoldByName(TITLE,TITLE2);</script>

0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments

Categories

0
Would love your thoughts, please comment.x
()
x