John P.

One Mans Blog

Specialization is for Insects.

Have you ever wondered how to show Google ads on your WordPress blog’s home page, but only after the very first article? Well, here is how you do it. And don’t worry, it’s quite simple, and you can’t permanently damage anything by giving it a try. ANYONE can do this!

  1. In the PRESENTATION menu, under THEMES EDITOR, find the theme file called “Main Index Template” (index.php).
  2. FIRST: Copy and paste everything you see here into a blank text file and save it. This way if you screw something up you can revert back to the original without hurting anything.
  3. Find a line of code that looks much like the following: <?php the_content('Read the rest of this entry »'); ?>
  4. Immediately after that, paste the following: <?php if ($count == 0) : ?> ENTER YOUR AD CODE HERE <?php endif; $count++; ?>
  5. Save the document and refresh your page. You should see the ad ONLY after the first article on the homepage.

Read the rest of this entry »

The Nice Person Freeware License

While creating a couple of plugins and themes for Wordpress I became confused, disillusioned and disenchanted with the various copyright licenses found around the net. I didn’t want anything so “legal-y” because, well frankly I’m not going to have the time, energy or patience to actually enforce it. Plus, I’m giving these things away for free!

So I decided to create my own licence as follows. Feel free to use / link to it if you feel it meets your needs, and suggestions for improvement are welcome.
Read the rest of this entry »


I use the "No Adverts for Friends" plugin by Donncha O Caoimh