/[bfilter]/trunk/hide.js
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /trunk/hide.js

Parent Directory Parent Directory | Revision Log Revision Log


Revision 14 - (show annotations)
Sun Sep 12 02:18:42 2004 UTC (19 years, 7 months ago) by dpavlin
File MIME type: application/javascript
File size: 715 byte(s)
not so small any more, but more powerful :-)

1 function toggle_display(name) {
2 var el = eval("document.getElementById('"+name+"')");
3 if (el) {
4 if (el.style.display=='none')
5 el.style.display = '';
6 else
7 el.style.display = 'none';
8 }
9
10 return false;
11 }
12
13 function set_display(name,display) {
14 var el = eval("document.getElementById('"+name+"')");
15
16 if (el) el.style.display = display
17 else alert("can't set_display("+name+","+display+")");
18
19 return false;
20 }
21
22 function show_display(show) {
23 for (var i = 0; i < show.length; i++) {
24 set_display(show[i],'');
25 }
26 }
27
28 function hide_display(hide) {
29 for (var i = 0; i < hide.length; i++) {
30 set_display(hide[i],'none');
31 }
32 }
33
34 function show_hide_display(show,hide) {
35 show_display(show);
36 hide_display(hide);
37 }

  ViewVC Help
Powered by ViewVC 1.1.26