fmckinnon
Member
Posted 1 month ago #
Hey Gang,
We use OpenX.org as our ad server, and it works great serving up banners on the websites. Our Ad agency is wanting to book campaigns in our RSS feeds now - I have no clue what file to edit, and where/how to insert the code.
The code is typically either a javascript or iframe code ...
We want the code to render the ads at the bottom of each article in the RSS feed.
Thanks in advance,
Fred
fmckinnon
Member
Posted 1 month ago #
Hey,
Thanks a ton - I've done this, and I'm assuming my ad-server code I placed in my functions.php file is OK, because i'm not getting any errors (at first, when I attempted to use the javascript of iframe code, it wouldn't work - so I'm using a simpler "image tag" code now).
But - nothing is showing up:
http://feeds.feedburner.com/fredmckinnon
Here's the functions.php code:
<?php
if ( function_exists('register_sidebars') )
register_sidebars(2);
?>
<?php
function insertAds($content) {
$content = $content.'<hr /><img src="http://d1.openx.org/avw.php?zoneid=81644&n=ac3c8466"><hr />';
return $content;
}
add_filter('the_excerpt_rss', 'insertAds');
add_filter('the_content_rss', 'insertAds');
?>
Works for me.
http://img24.imageshack.us/img24/2584/feedads.png
There's usually a lag with feedburner updates :)
fmckinnon
Member
Posted 1 month ago #
Interesting - yep, it works for me to if I load feeds.feedburner.com/fredmckinnon - but when I view my own feed in Google Reader, it only shows the Google Ads.
And since I assume most folks will be using Google Reader, I wonder if there's a way to resolve that?
Can you try subscribing in Google Reader to see if it works there?
fmckinnon
Member
Posted 1 month ago #
PS: incidentally,
I've subscribed to my RSS in Net News Wire and Apple Mail app, neither of which show the ads either. It seems that they make it to feedburner, and then disappear once picked up there. Maybe Feedburner is removing them?
You can't have both google ads AND your custom ads at the same time (among other things, it's a violation of Google's TOS).
fmckinnon
Member
Posted 1 month ago #
Gotcha - I've turned off the GoogleAds, but it didn't seem to make a difference, so I turned them back on.
Just remember, it can take up to 24 hours for FeedBurner to stop being a retard and recache things.
fmckinnon
Member
Posted 1 month ago #
feedburner actually shows the updates very quickly ... but the ads never come through into GoogleReader. I'm guessing it's a Google thing.