ZFGC

Resources => Coding => Topic started by: Fox on June 25, 2007, 05:57:10 pm

Title: HTML-help, please.
Post by: Fox on June 25, 2007, 05:57:10 pm
Right, so I want a picture to link to a different website. When I use this:
Code: [Select]
<a href="www.homepage.com"><img src="www.pictures.com/pic.jpg"></a>
then it does link to that site, but it has an ugly blue border around it. How can I prevent that?
Title: Re: HTML-help, please.
Post by: CrystalAngel04 on June 25, 2007, 05:58:28 pm
Code: [Select]
<a href="www.homepage.com"><img src="www.pictures.com/pic.jpg" border="0"></a>
I think.... don't hold me to it though
Title: Re: HTML-help, please.
Post by: Fox on June 25, 2007, 06:00:19 pm
Code: [Select]
<a href="www.homepage.com"><img src="www.pictures.com/pic.jpg" border="0"></a>
I think.... don't hold me to it though
You win several internets. It worked.
Title: Re: HTML-help, please.
Post by: nitz on June 25, 2007, 06:04:11 pm
Aye. "boarder" is technically a deprecated element, you should use CSS to define the border style as 0px or none, but most browsers still support it.
Title: Re: HTML-help, please.
Post by: TheRealDragonboy on June 27, 2007, 07:38:32 am
Aye. "boarder" is technically a deprecated element, you should use CSS to define the border style as 0px or none, but most browsers still support it.
Yeah you're right.

Code: [Select]
<style type="text/css">
img
{
  border: 0;
}
</style>

Use this fox, the most browsers supports it.
Title: Re: HTML-help, please.
Post by: nitz on June 27, 2007, 10:15:15 am
Correct. Another way to specify this style would to be in a span or other separating element:
Code: [Select]
<span style="border: 0;"><img src="lol.jpg" /></span>Forgive me if my syntax isn't exactly correct, it's been a few years since I've done a lot of web design and CSS, but I believe that's correct.
Title: Re: HTML-help, please.
Post by: Benito on June 27, 2007, 01:57:51 pm
Correct. Another way to specify this style would to be in a span or other separating element:
Code: [Select]
<span style="border: 0;"><img src="lol.jpg" /></span>Forgive me if my syntax isn't exactly correct, it's been a few years since I've done a lot of web design and CSS, but I believe that's correct.

That is similar to the above its just the css is located within the span and also its not a link, I find its best to use an external .css mostly.

Contact Us | Legal | Advertise Here
2013 © ZFGC, All Rights Reserved