 |
HTML Help Please Search for the answer to your question before asking it! Thanks.
|
| View previous topic :: View next topic |
| Author |
Message |
ron wolpa
Joined: 28 Feb 2005
Posts: 5
|
| Posted: Mon Feb 28, 2005 7:28 pm how to format frame border of <iframe>? |
|
|
<IFRAME style="WIDTH: 490px" src="anything.htm"
frameBorder=1
scrolling=no height=80 > </IFRAME>
Hi
Is there a way to format the border of iframe so that instead of having the uggly 3d default I will have a thin flat colour finishment line ? :?:
is there a way to control this by means an external CSS ?
Cheers |
|
|
ron wolpa
Joined: 28 Feb 2005
Posts: 5
|
| Posted: Wed Mar 02, 2005 7:40 pm |
|
|
| Hey , any answer ?? :?: :!: |
|
|
degsy
Joined: 23 Feb 2005
Posts: 2440
Location: North East, UK
|
| Posted: Thu Mar 03, 2005 5:37 am |
|
|
You can add a border but the style is defined by the Operating System style.
http://www.w3schools.com/css/ |
|
|
henkied
Joined: 07 Mar 2005
Posts: 22
|
| Posted: Mon Mar 07, 2005 2:45 am add a border |
|
|
you can add a border most browser wil show it
style="border:1px solid #000000"
wil replace the 3d border with a black one of 1 pixel
make it 0px to completely remove the border |
|
|
mackaltman
Joined: 09 Sep 2005
Posts: 1
|
| Posted: Fri Sep 09, 2005 8:44 pm THE ANSWER |
|
|
In an iframe you remove the iframe border (browser border) by placing a tag as follows:
<iframe frameborder="#"></iframe>
# = 1 for yes, and 0 for no
You're welcome, as well as the rest of you who should be thanking me, 3d borders suck so get rid of all of them. |
|
|
skhambadkone
Joined: 22 Aug 2008
Posts: 1
|
| Posted: Fri Aug 22, 2008 1:45 am |
|
|
mackaltman,
I wasted my time registering on this site just to thank you. Thank you. |
|
|
sticks464
Joined: 31 Dec 2006
Posts: 2906
|
| Posted: Fri Aug 22, 2008 4:01 am |
|
|
Sorry to hear you didn't find a satisfying answer to your question.
To style an iframe border the first thing to do is remove the border elements from the html and the height may be removed
Code: <IFRAME style="WIDTH: 490px" src="anything.htm"
scrolling="no"></IFRAME>
If you want inlne css it can be styled as such
Code: <IFRAME style="width:490px; height:80px; border:1px solid #000000;" src="anything.htm" scrolling=no></IFRAME>
If you want embedded css you must give the iframe an id or assign a class. Either one is fine and will do the same thing with the exception of id's may be used only once per page and a class may be repeated.
Embedded css goes in the head section of the page
Code: (using an id)
<IFRAME id="myframe" src="anything.htm" scrolling=no></IFRAME>
<style type="text/css">
#myframe {
width:490px;
height:80px;
border:1px solid #000000;
}
</style>
Code: (using a class)
<IFRAME class="myframe" src="anything.htm" scrolling=no></IFRAME>
<style type="text/css">
.myframe {
width:490px;
height:80px;
border:1px solid #000000;
}
</style> |
|
|
vysterr
Joined: 03 Mar 2010
Posts: 1
|
| Posted: Wed Mar 03, 2010 2:03 pm |
|
|
sticks464,
Your code helped me with getting the 1px border I needed, but then after I added that into my iframe, it no longer would show the page of the URL i was trying to locate.
my iframe code here shows the border, but not the webpage inside the iframe:
Code: <IFRAME name="main" src="/about2.htm" style="width:700px; height:600px; border:1px solid #fc4e4e;" allowtransparency="true"></IFRAME> |
|
|
| |
|
|
|
Powered by phpBB Search Engine Indexer
Powered by phpBB 2.0.19 © 2001, 2002 phpBB Group
|