Toon posts:

Beehiv: visibility: hidden lijkt niet te reageren

Pagina: 1
Acties:
  • 106 views sinds 30-01-2008

Verwijderd

Topicstarter
Hoi,

Voor op een site ga ik gebruik maken van de scrollbalk van Clay, en alles schijnt prima te werken. Maar omdat ik de site niet zelf ga beheren, wil ik alle layers in dezelfde html zetten. Nu heb ik een functie ergens opgedoken waarmee ik layers aan en uit kan zetten.

Bij elke layer in mijn document lijkt alles gewoon netjes te reageren. De layers waarin gescrolled moet worden lijken er juist niets van aan te trekken. Omdat alle content in principe in deze scrollbalken moet komen heb ik dus een behoorlijk probleem. Hoe kan ik de content in de scrolllayers (container en content) nou visibility: hidden maken?

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
<html>
    <head>
        <link rel=stylesheet type='text/css' href='kris.css'>
        <title>Soap 4 You .nl | VJ Kris</title>
<script language="JavaScript" type="text/javascript">
    
    ns4 = (document.layers)? true:false
    ie4 = (document.all)? true:false

    function show(id)                                                           {
        hideall();
            if (ns4) document.layers[id].visibility = "show"
            else if (ie4) document.all[id].style.visibility = "visible"
        if (id = "menu03")                                                      { 
        submenu = "true";                                                       }
                                                                                }

    function hide(id)                                                           {
            if (ns4) document.layers[id].visibility = "hide"
            else if (ie4) document.all[id].style.visibility = "hidden"
        if (id = "menu03")                                                      { 
        submenu = "false";                                                      }
                                                                                }

    function isVisible(id)                                                      {   
        if (ns4) return (document.layers[id].visibility == "show"); 
        else if (ie4) return (document.all[id].style.visibility == "visible");
                                                                                }

    function hideall()                                                          {
    hide('logo');
    hide('container');
    hide('content');
                                                                                }

</script>

<script language="javascript" src="src/beehive.js"></script>
<script language="javascript" src="src/dynscrollbar2.js"></script>


<style type="text/css">
#container  {position:absolute; width:196; height:240; left:310; top:86; 
             clip:rect(0,320,240,0); visibility:hidden;}
#content    {position:absolute; left:10; top:0; width:195; visibility:hidden;}
</style>

<script language="javascript">

var barOne;


scrollerBG = "graphs/transparant.gif";
upSRC      = "graphs/bar_up.gif";
downSRC    = "graphs/bar_up.gif";
scrollSRC  = "graphs/bar_up.gif";

scrollCursor = 'hand';
scrollerHeight = 13;
leftOffset = 7;
extraSpace = 13;


function init() {   
    barOne = new scrollbar(300,86,15,240);
    barOne.setLayer('content');

    }

</script>
</head>

<body bgcolor='#000000' leftmargin='0' topmargin='0'>

<div id='container' style="visibilty: hidden">
    <div id='content' class='text' style="visibilty: hidden">
    <b>content</b><br>
    Look in the source of this file, there's comment inside.
    <br><br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.<br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.<br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.<br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.
    <br><br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.<br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.<br>
    <br><br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.<br>
    This is just test content, don't read it. Music is what
    makes the world go round. Now turn of your computer and
    go outside. This is just test content, don't read it.<br>

    </div>
</div>
</div>

        
<script language="JavaScript">

function MM_swapImgRestore()                                                    {
  var i,x,a=document.MM_sr; 
  for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
                                                                                }

function MM_preloadImages()                                                     {
  var d=document; 
  if(d.images)                                                                  { 
  if(!d.MM_p) d.MM_p=new Array();
  var i,j=d.MM_p.length,a=MM_preloadImages.arguments; 
  for(i=0; i<a.length; i++)
  if (a[i].indexOf("#")!=0)                                                     { 
  d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];                                    }
                                                                                }
                                                                                }

function MM_findObj(n, d)                                                       {
var p,i,x;  
if(!d) d=document; 
if((p=n.indexOf("?"))>0&&parent.frames.length)                                  {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);             }
if(!(x=d[n])&&d.all) x=d.all[n]; 
for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && document.getElementById) x=document.getElementById(n); return x;
                                                                                }

function MM_swapImage()                                                         {
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; 
for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; 
if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];                                         }
                                                                                }
</script>


<center>

<!--start basistabel-->
<table width='615' height='400' cellpadding='0' cellspacing='0' border='1' background='graphs/bg_kris.jpg'><tr><td>

<!--div logo mtv logo_mtv.gif-->
<div id='logo' style='position: absolute; left: 5px; top: 374px; visibility: hidden'><a href='http://www.mtv.nl' target='new'>[img]'graphs/logo_mtv.gif'[/img]</a></div>

<!--div navigatie-->
<div id='home' style='position: absolute; right: 3px; top: 45px'><a href="#" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('img1','','graphs/but_kris_home_on.gif',1)">[img]'graphs/but_kris_home_out.gif'[/img]</a></div>
<div id='dagboek' style='position: absolute; right: 13px; top: 131px'><a href="#" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('img3','','graphs/but_kris_dagboek_on.gif',1)">[img]'graphs/but_kris_dagboek_out.gif'[/img]</a></div>
<div id='nieuws' style='position: absolute; right: 28px; top: 82px'><a href="#" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('img2','','graphs/but_kris_nieuws_on.gif',1)">[img]'graphs/but_kris_nieuws_out.gif'[/img]</a></div>
<div id='column' style='position: absolute; right: 41px; top: 242px'><a href="#" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('img5','','graphs/but_kris_column_on.gif',1)">[img]'graphs/but_kris_column_out.gif'[/img]</a></div>
<div id='fotos' style='position: absolute; right: 42px; top: 187px'><a href="#" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('img4','','graphs/but_kris_fotos_on.gif',1)">[img]'graphs/but_kris_fotos_out.gif'[/img]</a></div>
<div id='chatn' style='position: absolute; right: 9px; top: 294px'><a href="#" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('img6','','graphs/but_kris_chat_on.gif',1)">[img]'graphs/but_kris_chat_out.gif'[/img]</a></div>

</td></tr></table>

</center></body></html>

  • Pelle
  • Registratie: Januari 2001
  • Laatst online: 23-08 09:52

Pelle

🚴‍♂️

Als je iets over Beehive wilt weten, dan mail je maar met Clay.
Je manier van coden is trouwens vet irritant.

  • Pelle
  • Registratie: Januari 2001
  • Laatst online: 23-08 09:52

Pelle

🚴‍♂️

Oh ja, FYI: we zijn hier niet van de Sinisa helpdesk: http://gathering.tweakers.net/forum/find/poster/4677

Dit topic is gesloten.