Advertising
In WPtouch 4, advertising is now handled by the Basic Ads extension. You can read more about setting up and using Basic Ads in this article:
Basic AdsWPtouch Pro supports the inclusion of ad script from Google Adsense and offers a quick way to include code from other ad networks. You may customize the display location of your advertisements.
To include advertising in your mobile theme, choose the option to add either “Google AdSense” or “Custom”. Each will bring up its own set of options.
Service: Google AdSense
When Google AdSense is the selected service, enter your AdSense Publisher ID (in the pub-xxxxxxxxxxxxxx format) and Slot ID if you have one.
- If you find that your ads are not displaying, please make sure that the ad unit for the slot-id you are using in WPtouch Pro has a Status of “Active”. You may also try using a different code type: synchronous or asynchronous.
- “Adsense for mobile content” must be enabled in your Google AdSense Account Settings > Account Information.
- Select the 320×50 ad unit size when creating a new ad unit in Google AdSense. No other selections are valid for WPtouch Pro.
- Ensure you adhere to your service provider’s terms of service when adding advertising to your sites.
Service: Custom
Include mobile advertising script from any service in the custom field. To include your own banner image(s), include the HTMl code directly into the field. Example: http://pastebin.com/UsQwRYpX
Ad Presentation
You may choose where in your mobile theme you’d prefer to display your ads: in the header, above page content, or below page content.
Active Pages
You may choose on which areas of your site you want to display your ads: Blog Listings, Single Posts, Static Pages, Taxonomy, and/or Search Results.
If you prefer a custom location for your ad placement, you may customize the post and/or page templates. This will allow you to place your ad script anywhere in the theme layout. Details on customizing templates are in this documentation: Custom Templates
Adding Additional Advertising
The Multi-Ads Extensions allows you to easily add additional ad units. You may easily include ad units in the header, footer, pre-content, post-content, and mid-content areas. The Multi-Ads extension is available to 5-Pack license holders and up. Below are alternate methods of including additional advertising units in your WPtouch Pro theme.
Before adding additional ad units, please check if multiple ad units are allowed in a single page on mobile pages, according to your ad network’s guidelines.
Theme Footer
For security purposes, JavaScript is no longer supported in the Theme Footer section.
Single Posts
If you are using the native ad support and have configured ads to display in the header, you can show an additional ad unit in single posts by adding the ad code to the posts page template (single.php).
First, create and activate a copy of your WPtouch Pro theme in Themes & Extensions > Themes. Open /wp-content/wptouch-data/themes/_YOUR_COPIED_THEME_/default/single.php and add the ad code below the wptouch_the_content template tag to display the ads below the post content and above the wptouch_the_content template tag to display the ads above the post content. Please refer to the screenshot below.
In the header
If you are using the native ad support and have configured ads to display in below or above the post content, you can show an additional ad unit in the header area by adding the code the header-bottom.php template.
First, create and activate a copy of your WPtouch Pro theme in Themes & Extensions > Themes. Open /wp-content/wptouch-data/themes/_YOUR_COPIED_THEME_/default/header-bottom.php. To display the ads in the same place where WPtouch Pro’s native ad support displays them, you can add the ad code before or after the wptouch_advertising_top hook.
Google Double Click For Publishers Ads (DFP)
When using DFP advertisements, Google requires that a piece of code they provide be placed in the head section of the website. To accomplish this in WPtouch Pro, begin by creating a copy of your WPtouch Pro Theme in “Themes & Extensions > Themes”.
Then, open /wp-content/wptouch-data/themes/_THE_COPIED_THEME_/default/header-bottom.php. Add the code Google provides at the top of the header-bottom.php file and save the changes.
You may then add the ad code using the “Custom” advertising option in WPtouch Pro or via the Multi-Ads Extension.