PDA

View Full Version : Javascript - Dynamic HTML



Rostum
11-23-2004, 04:29 AM
Hey I've been having some issues with a javascript code, or I think it may be just Dynamic HTML, which I think it basically the same thing. Anyways. I have been wondering how to display the scroll bar inside the iframe even when there's nothing to scroll (you know, it gets greyed out), if that's possible?

Also, this isn't as important, but to get rid of the indent it has in Internet Explorer? It works fine in Firefox, which is what I use, but other people will be using IE. It's not such a big problem, it would just set a better mood for the site.

Here's the code:



<img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif><img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif><img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif><img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif><img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif><img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif><img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif><img src=http://forums.eyesonff.com/images/smilies/lovesmile.gif> name="cwindow" style="border:0px solid black" width=150 height=150 src="doc.htm"></iframe>


Edit: For some reason, love smilies are coming up, so go to this website to see what I'm talking about.

http://dynamicdrive.com/dynamicindex8/miniwindow.htm

Dr Unne
11-23-2004, 05:38 AM
&lt;div style="overflow: scroll; border: 5px white solid;width: 100px; height: 100px;">Testing.&lt;/div>

<div style="overflow: scroll; border: 5px white solid;width: 100px; height: 100px;">Testing.</div>



&lt;div style="overflow: auto; border: 5px white solid;width: 100px; height: 100px;">Teeeeeeeeeeeeeeeeeeeeeeeeeeeeeeesting.&lt;/div>

<div style="overflow: auto; border: 5px white solid;width: 100px; height: 100px;">Teeeeeeeeeeeeeeeeeeeeeeeeeeeeeeesting.</div>



&lt;div style="overflow: auto; border: 5px white solid;width: 100px; height: 100px;">Testing testing testing testing testing testing testing testing testing testing testing testing testing.&lt;/div>

<div style="overflow: auto; border: 5px white solid;width: 100px; height: 100px;">Testing testing testing testing testing testing testing testing testing testing testing testing testing.</div>

Rostum
11-23-2004, 05:59 AM
Thanks Unne.

Just a few questions... Can I call another page to put into the frame insead of just writing text into it? Also with the first one, is there a way to get rid of the bottom scroll bar but keep the side one?

Dr Unne
11-23-2004, 06:03 AM
That doesn't use iframes, it uses divs. One thing you can do is use server-side includes to include text into your page rather than iframes. iframes aren't supported by all browsers, for example, but SSI is, because it's server-side. Frames are generally evil.

I don't know of any way to keep the side bar but not the bottom one. Either you can force it to have both, or have it auto-detect, or force it to have neither. That's all I know how to do with CSS.

Rostum
11-23-2004, 06:08 AM
Hmm I guess, but I'm using it as the body of the webpage, so that the main layout doesn't exceed the browsers view. I can post up an example of it if you want.

Also I haven't had any problems with iframes and it is supported by the main browsers (i.e. Firefox, IE, Netscape). I don't know what other browsers are the mainstream.

Anyways thanks for the help, I might stick with iframes because I find it a bit better to load the pages in it, instead of loading the whole layout each page. And I can put in images in iframes.