Results 1 to 14 of 14

Thread: I'm Stuck - Border around a linked image - not as simple as I thought?

  1. #1

    Join Date
    Jan 2005
    Location
    baltimore
    Posts
    111
    Rep Power
    13

    I'm Stuck - Border around a linked image - not as simple as I thought?

    Ok so I've googled and seen countless websites instructing the border=0 stuff and even the a img {border:none;} stuff in the style sheet.

    Nothing works.

    Please take a look at the social media buttons on the left column of www.pizzapie24x7.com. It seems to me that these nifty 3D icons that I'm using have transparent backgrounds which means that the actual edge of the image is larger than the 3D visible icon itself. Do you see that little gray border? It's driving me crazy!

    How can I get rid of it?

    I think it has something to do with the fact that its a transparent PNG. I've saved it as 8 and 24- same thing.

    John
    Last edited by jarigo2; 4-18-12 at 10:22 PM. Reason: added PNG information

  2. #2
    Custom User Title tpoynton's Avatar
    Join Date
    Sep 2004
    Location
    Mass
    Posts
    2,177
    Rep Power
    17
    are you talking about the +1 and like buttons, or the square ones? i see the gray border around the rectangles (one of which is a div, the other is probably a div generated by js). for the square ones, I only see a little gray on the bottom right corner of two of them, something that can be easily fixed by opening the image in an editing program and erasing.

  3. #3

    Join Date
    Jan 2005
    Location
    baltimore
    Posts
    111
    Rep Power
    13
    Dont I look like a fool.

    Either its a powweb server issue or a browser refresh issue. Last night when I was pulling my hair out trying to figure this out apparently my changes were being made but I wasn't seeing them. This morning I wake up to a bunch of changes with no gray border. Its like my server or my browser doesn't see an immediate change.

    Oh I'm mad. At least the gray box is gone. It must have been one of the 100 things I tried last night with the image. oh boy.

  4. #4
    target='_blank' snowmaker's Avatar
    Join Date
    Nov 2002
    Location
    West Virginia
    Posts
    3,443
    Rep Power
    21
    You know, I went to your site shortly after your post last night, and saw the border issue you were having. I was about to reply, with some things to try out (that was last night, so I don't remember what I was going to say..), but I had to run off, real life was calling (it always seems to get in the way like that, dammit), but a few hours later when I made it back here, the issue seemed resolved. It could very well be a browser cache issue, that has reared its head here in a few different ways. And that pan pizza looks good!
    -bruce /* somdcomputerguy */
    'If you change the way you look at things, the things you look at change.'

  5. #5
    Custom User Title tpoynton's Avatar
    Join Date
    Sep 2004
    Location
    Mass
    Posts
    2,177
    Rep Power
    17
    must've been looking at a cached version on powweb servers...there is apparently some htaccess you can add to disable caching, sticky at http://forum.powweb.com/showthread.php?t=85763 .

    Caching is bad when you are trying to see changes, but good for server performance - yours and everyone else's. If you disable caching, I'd recommend re-enabling it by commenting out those lines in the htaccess file. it is an extra step, but only takes a minute or so to open the htaccess file, add/delete comment markers, and upload.

  6. #6

    Join Date
    Jan 2005
    Location
    baltimore
    Posts
    111
    Rep Power
    13
    Now I'm curious as to what did the "box removal"

    either my photoshop save for web options where I altered the png setting or this in my style sheet:

    a:link img{
    border: 0px solid #cccc99;
    }
    a:visited img{
    border: 0px solid #cccc99;
    }

    I changed the px from 1 to 0. The problem is I really don't know what I'm doing! lol

    Thanks anyway - its fixed, im running with it!

  7. #7
    target='_blank' snowmaker's Avatar
    Join Date
    Nov 2002
    Location
    West Virginia
    Posts
    3,443
    Rep Power
    21
    Well this border: 0px solid #cccc99; translates to this: a solid border 0 pixels wide (invisible..) which is a kinda greyish yellow color (which can't be seen since the border width is 0 px anyway). Basically, the border type and color aren't needed here.

    edit: oh, and the a:link and a:visited specify visited and unvisited anchors (links).
    Last edited by snowmaker; 4-19-12 at 09:02 AM. Reason: oh..
    -bruce /* somdcomputerguy */
    'If you change the way you look at things, the things you look at change.'

  8. #8

    Join Date
    Jan 2005
    Location
    baltimore
    Posts
    111
    Rep Power
    13
    A small embarrassing update: this was the fix:

    a:link img{
    border: 0px solid #cccc99;
    }
    a:visited img{
    border: 0px solid #cccc99;
    }

    I did it on another blog of mine and the gray box was there with the same images used on the pizza site. I went into style and changed 1px to 0 px and boom it went away.

    I could have saved about 3 hours last night if I would have known about the server cache issue! ha.

  9. #9

    Join Date
    Jan 2005
    Location
    baltimore
    Posts
    111
    Rep Power
    13
    Quote Originally Posted by snowmaker View Post
    Well this border: 0px solid #cccc99; translates to this: a solid border 0 pixels wide (invisible..) which is a kinda greyish yellow color (which can't be seen since the border width is 0 px anyway). Basically, the border type and color aren't needed here.

    edit: oh, and the a:link and a:visited specify visited and unvisited anchors (links).
    Oh just saw this reply. So you think I have some unnecessary code in there? It seems to be working fine I assume I should just leave it be? I wonder how that got in there? Oh yes, about 5 years of me screwing around with a style sheet. :-)

  10. #10
    target='_blank' snowmaker's Avatar
    Join Date
    Nov 2002
    Location
    West Virginia
    Posts
    3,443
    Rep Power
    21
    It's ok to leave it there, unless you need the space the unused 30 or so characters takes up..
    -bruce /* somdcomputerguy */
    'If you change the way you look at things, the things you look at change.'

  11. #11

    Join Date
    Jan 2005
    Location
    baltimore
    Posts
    111
    Rep Power
    13
    Quote Originally Posted by snowmaker View Post
    It's ok to leave it there, unless you need the space the unused 30 or so characters takes up..
    Thanks Bruce!

  12. #12
    target='_blank' snowmaker's Avatar
    Join Date
    Nov 2002
    Location
    West Virginia
    Posts
    3,443
    Rep Power
    21
    You bet man.
    -bruce /* somdcomputerguy */
    'If you change the way you look at things, the things you look at change.'

  13. #13
    Custom User Title entrecon's Avatar
    Join Date
    Aug 2006
    Location
    Michigan
    Posts
    2,742
    Rep Power
    16
    I don't know that you are using one, but if you have something like WordPress or Joomla they also have a cache funtionality that you might need to clear when working on this type of stuff.
    ________________________________
    Find me on twitter: @entrecon

  14. #14

    Join Date
    Jan 2005
    Location
    baltimore
    Posts
    111
    Rep Power
    13
    Quote Originally Posted by entrecon View Post
    I don't know that you are using one, but if you have something like WordPress or Joomla they also have a cache funtionality that you might need to clear when working on this type of stuff.
    No, I'm doing straight .shtml files uploaded to the ftp server. So if there is a cache issue it would either be my browser or Powweb.

Posting Permissions

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