![]() |
AdSense for Mobile Content
AdSense for Mobile Content in VB Templates
If you have ever attempted to create the Adsense for Mobile Content then you probably hit a stumbling block when it didn't give you the code it normally provides for regular ads. The problem is you cant just copy paste the code google gives you and expect it to work. Google gives you the following four options and none of these can be pasted into VB Templates. AdSense for Mobile Content generated code options. PHP CGI/Perl JSP ASP Here is the PHP Solution How to add Adsense for Mobile Content into your VB mobile template using the PHP include code bits. Requirements: 1 New Plugin 1 New File 1 Template Edit Instructions: Since the information you need to put in all three of these will vary on your server paths, I dont know any way to give you a plugin to import that wouldn't require you to change it anyway. You will need to create these manually. Some of this I found in the VB handbook. 1. Create a Plug-in for global_start with these contents: Code:
ob_start(); --------------- 2. Create the PHP file Login to your Google Adsense account and create a AdSense for Mobile Content. Choose Server-side scripting language: PHP Since the contents of this PHP file will be different for everyones individual account you will need to create it. When you see Your AdSense code showing in PHP, copy that into a newly created PHP file and call it "mobilead.php" Upload the file to your root directory or where ever you wish to have it reside. --------------- 3. Template Change Place $mobileadsense in one of your templates, such as header, navbar, FORUMHOME, depending upon where you want the mobile ads to display. Your done! If you wish to create more than one ad, just repeat the process and use a different name on the files and variables. Enjoy! If you use this, please click install |
If only google didnt ban me in the early days id give this a go now :/
|
Not working for me.
|
Are you testing using your PC browser? If you are it wont display. Google designed the code to only appear if you are using a mobile device. Confirm your testing with a mobile.
|
Thanks il give it a go
|
Thanks! This is exactly what I was looking for... however, I can't get any ads to display - I'm not getting any errors.
|
Thanks! Works great!
|
Recently this plugin has had a major impact on the speed of my site. I had to uninstall. Any ideas?
|
how do i make it work on mobile style 4.2 ?
|
All times are GMT. The time now is 11:48 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|