3.145.60.166 |    

Navigation

Google Advertisement

This function change the visibility style of an object.

ChangeLayer
  1. /***************************************************
  2.  * This function change the visibility style of 
  3.  * an object.
  4.  **************************************************/
  5. var ie4 = (document.all) ? true : false;
  6. var ns4 = (document.layers) ? true : false;
  7. var ns6 = (document.getElementById && !document.all) ? true : false;
  8.  
  9. function ChangeLayer( obj, sty ) {
  10.  
  11. var visit = new Array();
  12. visit['hide'] = "hidden";
  13. visit['show'] = "visible";
  14.  
  15. if (ie4) if (document.all[obj]) document.all[obj].style.visibility = visit[sty];
  16. if (ns4) if (document.layers[obj]) document.layers[obj].visibility = sty;
  17. if (ns6) if (document.getElementById([obj])) document.getElementById([obj]).style.visibility = visit[sty];
  18.  
  19. }
  20.  
Parsed in 0.001 seconds at 1133.34 KB/s

Search
 
Full text search by name and content of a snippet.

User online
There are 4 users online.

Tags Cloud

Latest snippets
str2seconds
(Bash::Function)
is_integer
(Bash::Function)
file_rotate
(Bash::Function)
confirm
(Bash::Function)
is_workingtime
(Bash::Function)
last day of last month
(Bash::Snippets)
crypt_apr1_md5
(PHP::Function)
crypt_apr1_md5
(Perl::Function)
transparent
(CSS)
rfc2822Toiso8601
(PHP::Function)