View Full Version : transparent iframes
Melancholy 06-18-2003, 04:25 AM i searched this forum and couldn't find anything that could help me
i am using absolute positioning and i want to have an iframe that has a transparent background. but i'm using an external stylesheet. I've tried other sites and the things on this site and it's not working, but i think it's because it's for people that aren't using external stylesheets. if anyone can help me, i'd appriciate it!
angelivion 06-18-2003, 11:15 AM did you use this code:
<iframe ALLOWTRANSPARENCY="true" style="filter:chroma (color=#694E8B); the rest of the stuff">
and is the hex color in bold similar to the background color of the pages inside the iFrame?
yeah, the hex color could be of any colour of course.
p/s: i often use div positioning to position my iframes which also uses external stylesheets. they work perfectly for me.
Melancholy 06-18-2003, 06:16 PM well see, the only thing is that i want the iframe to be completely transparent. when i did the chroma thing, it made the words transparent as well. i might not have been doing it right. i have an image under it so i didn't want a background color or anything. will what you posted still do that?
Melancholy 06-18-2003, 06:39 PM i've been messing around with the code some more, and instead of an iframe, i put just text and did overflow:auto in the css, and it scrolls. The only thing is, with the way i've done it now, is it still possible to do transparent scrollbars? if it is, you don't have to post a code for it, I can find it, but i am not sure if it'll work unless if i use an actual iframe for it
Greytail 06-19-2003, 02:48 PM When working with iframes in an image layout, you have to do a few things to get it to look the way you want. You can't really stick a chroma tag on the color of the background because, like you said, it does affect the text.
However, you can have the image show up as well as the scrollbar. Just take your image into any image editing program, and save the part that you want to show up as the background in your iframe as a separate file. Then, set it as the background for the page(s) that will be inside of the iframe.
If you want your scrollbar to be transparent, just leave the chroma tag in and set the scrollbar to the cooresponding color.
MiaBabie 06-19-2003, 06:57 PM Originally posted by Greytail
If you want your scrollbar to be transparent, just leave the chroma tag in and set the scrollbar to the cooresponding color.
Or you can use a DHTML scrollbar. Codephobia (http://www.codephobia.com/tutorials/view.php3?idnum=1) has a great tutorial to help you figure it out, or just send me a message and I'll help you.
Greytail 06-19-2003, 07:54 PM I personally find the regular scrollbars much more convenient. I'm a big fan of the wheel on my mouse, and usually use it to scroll, and you can't do that with DHTML scrollbars. I just find that your normal scrollbars work better, as well.
Jchan 06-23-2003, 08:17 PM I tried <iframe ALLOWTRANSPARENCY="true" style="filter:chroma (color=#694E8B); the rest of the stuff"> and it doesn't seem works.
My iframe code goes like this <iframe ALLOWTRANSPARENCY="true" style="filter:chroma(color=#OOOOOO); SRC="http://jchan.sphosting.com/menu.html" TITLE="Welcome" FRAMEBORDER=[1] SCROLLING=[yes]></IFRAME></td>
It doesn't work. I was wonderin if u have any idea why.
Jchan
MaGiCSuN 06-23-2003, 09:05 PM <iframe ALLOWTRANSPARENCY style="filter:chroma(color=#000000); SRC="http://jchan.sphosting.com/menu.html" TITLE="Welcome" FRAMEBORDER="1" SCROLLING="yes"></IFRAME>
now put on the page that opens inside the frame the scrollbar codes and set colour to #000000 and the scrollbar will become transparent. change #000000 to something like lime, it must not be on the page in the content or else that will become transparent too.
Works perfectly for me with divs too :)
edit: take out the spacing in code between " and filter, because the forum makes those spacing in it.
Love,
Mirna
kittycat 06-23-2003, 09:10 PM One more slight modification, forgot a " ;)
<iframe ALLOWTRANSPARENCY="true" style="filter:chroma(color=#0000
00);" SRC="http://jchan.sphosting.com/menu.html" TITLE="Welcome" FRAMEBORDER="1" SCROLLING="yes"></IFRAME>
It will work without the "true" after allowtransparency, but it's better to have it in there.
Jchan 06-23-2003, 10:45 PM hmmmm sure it works for you? Cuz i changed and added wat i missed. it still doesn't work. I changed the color to lime.
I want to make sure i got the code right
<iframe ALLOWTRANSPARENCY="true" style="filter:chroma(color=#00FF00;" SRC="http://jchan.sphosting.com/menu.html" TITLE="Welcome" FRAMEBORDER="1" SCROLLING="yes"></IFRAME>
J-chan
kittycat 06-23-2003, 11:30 PM style=" filter:chroma(color=#00FF00;"
should be
style=" filter:chroma(color=#00FF00);"
Jchan 06-24-2003, 02:01 AM uhh im sorry but theres still no change. Theres no transpancy to the background. Can you see it? http://jchan.sphosting.com/index.html
MaGiCSuN 06-24-2003, 06:09 PM the forum makes a space in the coding, and i think kittycat meant that. you have to take out the spacing in the code before the word "filter"
Love,
Mirna
Jchan 06-24-2003, 06:36 PM i did eliminate the space before the "filter" And theres no change.
kittycat 06-24-2003, 08:41 PM I looked at your code and noticed that you used some sort of javascript for coloured scrollbars. I'm not sure if this will make a difference or not, but you could try changing it to CSS and seeing if that changes it. (you want those to be transparent, right?)
Jchan 06-24-2003, 08:44 PM well i only wanted the background to be transparent. I prefer the scroll bars and texts to be solid.
kittycat 06-24-2003, 08:57 PM In that case you need to set a background colour... I didn't see that in there anywhere.
Jchan 06-24-2003, 09:42 PM Alright it works! :D I didn't know that u have to put same color background on both pages. Thank u so much! ::hug:: Umm one more question lol i was wonderin if its possible to get rid of iframe border.. if not can u change color of the border?
kittycat 06-24-2003, 09:53 PM frameborder="0" border="0"
Jchan 06-24-2003, 10:03 PM Thanks a lot for your help! :) :hug:
|