Text-Link-Ads Updated

Text-Link-Ads is a nice ser­vice which I use to help pay the bills for run­ning this site. They just released a new ver­sion of their Word­Press plu­gin which I use to put their adverts on this site, so I installed it but in doing so it over­wrote a cou­ple of changes I’d made to the old plu­gin. I had made those changes as I like the ser­vice and I def­i­nitely like the addi­tional income1, but I don’t like how the plu­gin makes the ad links less than obvi­ously ads. So my changes in the plu­gin add a spe­cific class which I can then style via CSS. Since I don’t want to have to keep redo­ing my cus­tomiza­tions from scratch each time they release the plu­gin; I’m post­ing the code changes I make here.

Under func­tion out­putHtm­lAds(), I changed the fol­low­ing line of code from:
echo "\n<ul>\n";</ul>

to:
echo "\n<ul class=\"tla_sponsor_link\">\n";</ul>

Also under func­tion returnPostAd($postId), I changed:
return "\n\n<em>".$prefixes[$prefixIndex].":</em> $ad->before_text <a href=\"$ad->url\">$ad->text</a> $ad->after_text";

to:
return "\n\n<div class=\"tla_sponsor_link\"><em>".$prefixes[$prefixIndex].":</em> $ad->before_text <a href=\"$ad->url\">$ad->text</a> $ad->after_text</div>";

Side note: TLA, you guys should change the Our Blog to be called some­thing else as the link doesn’t actu­ally take users to your blog.

1 I don’t make enough from these ads to get rich mind you. Just enough to cover the costs of run­ning CoffeeBear.net and maybe a cup of good cof­fee from my local cof­fee shop.

Similar Posts

About Mark McKibben

Mark works as a [REDACTED] for [REDACTED], currently residing in Iowa. CoffeeBear.net is a place for him to blather on about whatever strikes his fancy. He currently spends his "free" time working on a photography project, playing with his cat and attempting to keep his wife happy (not necessarily in that order).

Leave a Reply

Notify me of followup comments via e-mail. You can also subscribe without commenting.