Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

theNIC

macrumors member
Original poster
Apr 8, 2009
42
0
Sorry for the long title, didn't really know what to name it.

Anyways, I'm helping out my friend with this script, and I was wondering how do I get rid of this border on the image? (No it's not border="0")

Here's a screenshot and my source:

Ok for some reason my image isn't showing up, but here's a link to the screenshot: http://tinypic.com/r/vd2zh1/4

http://thecurseofcurves.com/ad.js

I know my padding on my links are causing it (in my CSS), but there has to be an easy way around this. Any help is greatly appreciated.
 
That's not strictly a border. It's the formatting on the parent <a> tag.

I'd suggest you change the CSS for the a selector:

Code:
a {
    color: #FFF;
    text-decoration: none;
}

Then add

Code:
a p {
    display: inline;
    background: #CCC;
    padding: 2px;
}

Then in the HTML, instead of

HTML:
<a href="http://thecurseofcurves.com/site/advertising.php">
    Advertise Here
</a>
enclose the text in a <p> tag

HTML:
<a href="http://thecurseofcurves.com/site/advertising.php">
    <p>Advertise Here</p>
</a>

Now you won't see the grey box behind the image as it's parent tag is <a> and not <p>.
 
Thanks, it worked but is there any way I can keep my padding on my regular links, or no?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.