472,145 Members | 1,555 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,145 software developers and data experts.

border around image link


ok here's my problem my markup is Xhtml strict so i am unable to place
border="0" in my img tag. I want to be able to get rid of this border
but have been un able to figure out how to do thi with CSS

the section that i need to remove the border from is this

.sub_menu_img A
{
PADDING-RIGHT: 0.5em;
DISPLAY: block;
PADDING-LEFT: 0.75em;
BACKGROUND: #fff;
PADDING-BOTTOM: 1.25ex;
COLOR: #666;
LINE-HEIGHT: 1.25em;
PADDING-TOP: 1.25ex;
TEXT-DECORATION: none;
}

so what do i need to do?

i have tried:

BORDER: none

and

BORDER-TOP: none;
BORDER-BOTTOM: none;
BORDER-LEFT: none;
BORDER-RIGHT: none

and neither of these seems to work

any help would be completly appreciated
--
DiGEnig
------------------------------------------------------------------------
DiGEnig's Profile: http://www.highdots.com/forums/m1824
View this thread: http://www.highdots.com/forums/t3240442

Jan 31 '06 #1
5 15218
Els
DiGEnig wrote:
ok here's my problem my markup is Xhtml strict so i am unable to place
border="0" in my img tag. I want to be able to get rid of this border
but have been un able to figure out how to do thi with CSS

the section that i need to remove the border from is this
No, it isn't ;-)
.sub_menu_img A
What is the element that has class 'sub_menu_img' ? Not the image I
hope? I'll assume it's the parent element around <a>.
so what do i need to do?


The image is having the border, so:

..sub_menu_img a img{
border:none;
}

Means: no border on the image that's a child element of the a element
that's the child of the element with class sub_menu_img .

--
Els http://locusmeus.com/
accessible web design: http://locusoptimus.com/

Now playing: Jon Anderson - Heart of the Matter
Jan 31 '06 #2
Els wrote:
..sub_menu_img a img{
border:none;
}

Means: no border on the image that's a child element of the a element
that's the child of the element with class sub_menu_img .


s/child/descendant/
--
Johannes Koch
Spem in alium nunquam habui praeter in te, Deus Israel.
(Thomas Tallis, 40-part motet)
Jan 31 '06 #3
Els
Johannes Koch wrote:
Els wrote:
..sub_menu_img a img{
border:none;
}

Means: no border on the image that's a child element of the a element
that's the child of the element with class sub_menu_img .


s/child/descendant/


True.

--
Els http://locusmeus.com/
accessible web design: http://locusoptimus.com/

Now playing: King Crimson - Thela Hun Ginjeet
Jan 31 '06 #4
DiGEnig <Di************@no-mx.forums.yourdomain.com.au> wrote in
news:Di************@no-mx.forums.yourdomain.com.au:

ok here's my problem my markup is Xhtml strict so i am unable to
place border="0" in my img tag. I want to be able to get rid of this
border but have been un able to figure out how to do thi with CSS

the section that i need to remove the border from is this

.sub_menu_img A


This is backwards if I understand you correctly. This would set the
properties for a in a .sub_menu_img class. What you need to do is set
properties for the image inside an a as in:

a img { border: 0 }

or just in that class:

..sub_menu_img a img { border: 0 }

HTH

--
Stan McCann "Uncle Pirate" http://stanmccann.us/pirate.html
Webmaster/Computer Center Manager, NMSU at Alamogordo
http://alamo.nmsu.edu/ There are 10 kinds of people.
Those that understand binary and those that don't.
Jan 31 '06 #5

Thank you very much that worked
The image is having the border, so:

..sub_menu_img a img{
border:none;
}

Means: no border on the image that's a child element of the a element
that's the child of the element with class sub_menu_img .


thanks again for all your help
--
DiGEnig
------------------------------------------------------------------------
DiGEnig's Profile: http://www.highdots.com/forums/m1824
View this thread: http://www.highdots.com/forums/t3240442

Jan 31 '06 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

10 posts views Thread by Vigil | last post: by
33 posts views Thread by Thomas Mlynarczyk | last post: by
15 posts views Thread by Oliver | last post: by
1 post views Thread by Keith Smith | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.