Jembelisme Media News, Opinion, Monetize, Link Exchange, Web Technology and Internet

Jembelisme Media
Posted Under: > > >

Disable Infolinks Ads in Specific Post or Page

08.27.2010 · Posted in Monetize, My Stories, Tutorials

Infolinks is one provider of in-text advertising service that allows owners of Web Content or commonly called Web Publisher, to obtain benefits from In-text advertising as advertising revenue without the risk.

You just put this code to your site before </body> HTML tag:

<script type="text/javascript">
   var infolink_pid = xxxxxx;
   var infolink_wsid = x;
</script>
<script type="text/javascript" src="http://resources.infolinks.com/js/infolinks_main.js"></script>

or, if you use wordpress as your site, you can use Infolinks Official Plugin by Infolinks. Fill your infolink_pid for your Infolinks account and infolink_wsid for your site, Infolinks ads will appear on all of your post and page immediately.

But, if you do not want to show infolinks ads on specific posts, you just add <!–INFOLINKS_OFF–> into the starting of your content in HTML mode.

I have a different solution with the method above, by using Costum Fields in every post on wordpress. Now, I’ll show you how to get started. Edit your single.php and page.php using theme editor. Then, put this code before <?php the_content(); ?>:

<?php
  $mykey_values = get_post_custom_values('disable_infolinks');
  if ($mykey_values[0] == "1")
    echo "<!--INFOLINKS_OFF-->";
?>

And put this code after <?php the_content(); ?> to show Infolinks Ads in other place:

<?php
  if ($mykey_values[0] == "1")
    echo "<!--INFOLINKS_ON-->";
?>

Finally, create a new custom field with name “disable_infolinks” (whitout quote). Fill value 1 for disable Infolinks ads on specific post or page.

So easy and good luck!

12 Responses to “Disable Infolinks Ads in Specific Post or Page”

  1. lha kok repot? hapus aja kodenya, lak yo ilang..

    • :uhuk: Begini mas det, mungkin tutorial atau cara ini sangat bermanfaat bagi para blogger yang membuat postingan review dari SR, BBR, BV, dll.. Jadi di postingan yang dibuat tersebut, tidak ada link-link yang muncul kecuali link berupa anchor text, sedangkan postingan yang lainnya akan tetap menampilkan Infolinks In text Ads.

    • mas det, dibaca judulnya yaaa…. "In Specific Post or Page"

      capek deh… :hai:

  2. aku gak paham

    hehehehe

    berkunung saja,,,

  3. okethax :hehe:

  4. wah manteb mas infonya

    tp buat blogspot bisa ndak :rambut:

    • bisa mas qsew, hanya saja untuk kode php di atas tidak bisa digunakan.. Nah, caranya cukup menambahkan kode <!–INFOLINKS_OFF–> di awal postingan dan <!–INFOLINKS_ON–> di akhir postingan pada mode HTML .

  5. makasih infonya

    salam hangat dari blue

  6. Reza Saputra says:

    punyaku juga gak ada bro :D

  7. blog saya pake bahasa indonesia.. jadi ditolak :D

  8. sip mas Anas…

    biru backgroundmu terlalu menyala mas… kesannya silau… mengganggu ketenangan membaca, coba cari warna biru yang teduh.. coba biru ini: 006699

    sapa tau cocok, wekkekke

Leave a Reply