On Sep 10, 2014, at 9:22 PM, Karl DeSaulniers <k...@designdrumm.com> wrote:

> 
> On Sep 10, 2014, at 9:20 PM, Karl DeSaulniers <k...@designdrumm.com> wrote:
> 
>> 
>> On Sep 10, 2014, at 9:17 PM, Karl DeSaulniers <k...@designdrumm.com> wrote:
>> 
>>> 
>>> On Sep 10, 2014, at 8:22 PM, John <j...@coffeeonmars.com> wrote:
>>> 
>>>> at the beginning of my css, I have this:
>>>> 
>>>> a img{
>>>>    border:none;
>>>> }
>>>> 
>>>> However, I am finding that my linked images have my link attribute which 
>>>> is border-bottom:1px dotted black.
>>>> 
>>>> Why is the a img rule being ignored/overwritten?
>>>> 
>>>> Page is here:  http://www.coffeeonmars.com/170_su/client/portfolio/
>>>> 
>>>> Thank you for  any ideas about this!
>>>> 
>>>> John
>>> 
>>> 
>>> Hi John,
>>> Try this...
>>> 
>> 
>> Alternatively you could maybe do something like this.
>> 
>> img:only-child {
>>      border-bottom:1px dotted rgb(0,0,0) !important;
>> }
>> 
>> and make sure your images are wrapped in a div.
>> 
> 
> Oops that should be...
> 
> img:only-child {
>       border-bottom:0px dotted rgb(0,0,0) !important;
> }
> 

Yep, just tested this theory and it worked for me.
Wrap your images you dont want a border on in a div and put this css.

CSS ---------------


/* ++++++++++++++++ RESETS ++++++++++++++++ */
*{margin:0;padding:0;}

/* ++++++++++++++++ LINKS & NAV ++++++++++++++++ */
a:link{
        text-decoration:none;
        border-bottom:1px dotted rgb(0,0,0);
        color:rgb(0,0,0);
}
a:visited{
        text-decoration:none;
        border-bottom:1px dotted rgb(0,0,0);
        color:rgb(0,0,0);
}
a:hover{
        color:rgb(206,4,4);
        border-bottom:1px dotted rgb(0,0,0);
}
a:focus{
        color:rgb(206,4,4);
        border-bottom:1px dotted rgb(0,0,0);
}
img:only-child {
        border-bottom:0px dotted rgb(0,0,0) !important;
}


HTML ------------------------------
...
<div id="right-col">
        <div id="text-6" class="widget widget_text">
                <div class="textwidget">
                        <a class="img" 
href="http://www.coffeeonmars.com/170_su/client/category/illustration/";>
                                <h3 class="three-col-box-head">illustration</h3>
                                <div><!-- ADDED THIS HERE, NOW IMG IS ONLY 
CHILD-->
                                        <img 
src="http://www.coffeeonmars.com/170_su/client/wp-content/themes/coffee-on-mars-2014/images/illus.jpg";
 width="270" height="270" alt="web thumbnail">
                                </div>
                        </a>
                          <p>See my illustration. <span class="more"><a 
href="http://www.coffeeonmars.com/170_su/client/category/illustration/";>More 
&gt;</a></span></p>
                </div>
        </div>
</div>
...

Karl DeSaulniers
Design Drumm
http://designdrumm.com

______________________________________________________________________
css-discuss [css-d@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to