WordPress.org

Ready to get started?Download WordPress

Forums

How to replace adsense code with the adsense for mobie php code in mobile browse (3 posts)

  1. Akhilraj
    Member
    Posted 7 months ago #

    How to replace adsense code with the adsense for mobie php code in mobile browse

  2. shandiz
    Member
    Posted 7 months ago #

    A. From Your Google Dashboard

    1. Generate your AdSesne for Mobile codes
    2. Open Notepad and Paste the generated Code
    2. Save Notepad as “adsense.php” without the quotes
    4, Upload “adsense.php” to the root directory where you installed your wordpress.

    B. On Your Cpanel Where You Have WordPress Installed.

    5. Navigate to Public_html > wp-content > plugins> mobilepress> system> theme> default/
    6. Locate “header.php” and edit with your Cpanel editor
    7. Find (CTR.F) this code below

    <?php mopr_ad('top'); ?></div>

    8. Right below the code above, insert this code below

    <div align="center"> <?php include('adsense.php'); ?> </div>

    so it looks like this

    <div><?php mopr_ad('top'); ?></div>
    <div align="center"> <?php include('adsense.php'); ?> </div>

    9. Following all the steps above will place mobile AdSense on your mobile header, if you want AdSense to show on your footer, follow the same process above, but “footer.php” would be the file to be edited.

    Wait for about 10 minutes, access your blog on your mobile phone and see beautiful ads runing.

    ref : http://www.thatnaijablog.com/2012/09/how-to-insert-mobile-adsense-into.html

  3. Akhilraj
    Member
    Posted 7 months ago #

    thanx but i am talking about another thing,
    i have both mobile and pc visitors. So i want to show the php code(adsense for mobile code) to mobile users and hide the javascript code.

Reply

You must log in to post.

About this Topic

Tags

No tags yet.