Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Jul 2009
    Posts
    78
    Thanks
    2
    Thanked 0 Times in 0 Posts

    override image style

    hi friends,

    i have a content div, aptly classed "content".
    in my content css i specify that i want all images resized to 590px.

    however, i have just ONE kind of image which sits inside a div with it's own class, "author" (which sits inside the "content" div). i'd like the image inside the author div to be a different size - 300px to be precise.

    I tried just putting in

    Code:
    .author img{
    max-width:300px;
    min-width: 300px;
    height: auto;
    }
    but the .content img code is overriding the .author img code i guess because of the heirachy of the div or whatever.

    any way to fix this?

    x

  • #2
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,863
    Thanks
    160
    Thanked 2,224 Times in 2,211 Posts
    any way to fix this?
    Need to see your complete html+CSS or a link to your page. You may set an id on that particular image to make a more specific selector.
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #3
    New Coder
    Join Date
    Jul 2009
    Posts
    78
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Unfortunately I'm working in maintenance mode so none of the pages are publicly viewable. I will try the id and if I can't get it to work I could probably set up an account for someone to look in and see?

  • #4
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,863
    Thanks
    160
    Thanked 2,224 Times in 2,211 Posts
    Unfortunately I'm working in maintenance mode so none of the pages are publicly viewable.
    That's why I used the OR option my post.
    Last edited by abduraooft; 10-28-2010 at 11:39 AM.
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • #5
    New Coder
    Join Date
    Jul 2009
    Posts
    78
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Thanks id worked!


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •