
How to display the Entrecard widget only at your main page
September 1st, 2009 by Andreas from Xavier Media® in Blogging, CGI & PHP, SampleAddress.com, The World According to Xavier, Tutorials. Topics: Banner Exchange, Entrecard, widget, WordpressToday Entrecard will stop rewarding site owners for displaying the Entrecard widget at their web site
since only the person dropping will get credits as of now and not the blog too as it used to be in the good old days.
Since you as the site owner is not getting anything for displaying the widget it's just a waste of useful advertising space to show the widget on all your pages, and therefore it could be a good idea to only show the widget at your main page instead of site-wide.
If you use for example self-hosted WordPress as your blogging platform it's quite easy to only display the widget at your main page. Just open the WordPress template where you have the widget code (footer.php for example) and replace the widget code with this code instead:
<?php if ( is_home() ) { ?>
<CENTER>
<script src="http://entrecard.s3.amazonaws.com/widget.js?user_id=XXXX&type=standard_127" type="text/javascript" id="ecard_widget"></script>
</CENTER>
<?php } ?>
Replace XXXX with your Entrecard ID (can be found in your HTML code) and you're ready to go. Whenever a user is watching the main page of your blog they will find the widget code (the Entrecard scanner will of course too), but if the user is watching any other page the widget will not show up.
If you would like to have the Entrecard widget replace by another ad network (that's actually rewarding for side-wide placements
), then just use the following code:
<?php if ( is_home() ) { ?>
<CENTER>
<script src="http://entrecard.s3.amazonaws.com/widget.js?user_id=XXXX&type=standard_127" type="text/javascript" id="ecard_widget"></script>
</CENTER>
<?php } else { ?>
<CENTER>
<!– ADD THE CODE TO SHOW ON ALL YOUR OTHER PAGES HERE –>
</CENTER>
<?php } ?>
So now you can show the Entrecard widget on your main page and on all other pages you can show for example the code from a banner exchange instead. This is a much more efficient way of displaying ads on your site
You may also be interested in...
The end of Entrecard?
AboutUs.org widget – finally
Strange Entrecard messages






September 4th, 2009 at 6:50 am
Hey Andrea, Are you going to stop showing your Entrecard widget? I think it's still a good ad tool and it get's people coming to ones blog. I really don't care for all of the changes either but I think it will work out in the end with the new owners.
.-= jj-momscashblog´s last blog ..Make Money Selling Used Books =-.
September 4th, 2009 at 6:53 am
We will still show the Entrecard widget, but only at the main page because they are not rewarding for having the widget site-wide. On the other pages we will use the space for other widgets that reward for more exposure.
September 16th, 2009 at 1:02 pm
I've been looking for this from many days ultimately found it here thanks a lot
.-= Imran | IT Buzz´s last blog ..Increase your ram with usb drive =-.