Results 1 to 3 of 3
-
14th Nov 2009, 03:41 PM #1OPMember
[Help] How to Show Ads Only to Visitors Coming from Search Engines
Hello Friends, i am here to get some help from you !
I have a vbulletin forum and I want to show my forum ads only to search engine users like google, yahoo or bing...
I know this is possible but i don't know how to use it so please if any one know this then please share this with me and i think many other users also will like this tooo.
Here i have a code for Wordpress but not for vBulletin (If any one can convert this for vbulletin it will be highly appreciated.
First, you have to create a function. paste the code below in your theme functions.php file. Create that file if it doesn't exists.
PHP Code:function scratch99_fromasearchengine(){
$ref = $_SERVER['HTTP_REFERER'];
$SE = array('/search?', 'images.google.', 'web.info.com', 'search.', 'del.icio.us/search', 'soso.com', '/search/', '.yahoo.');
foreach ($SE as $source) {
if (strpos($ref,$source)!==false) return true;
}
return false;
}
Then, paste the following code anywhere on your template where you want your adsense ads to appear. They'll be displayed only to visitors comming from search engines results.
PHP Code:if (function_exists('scratch99_fromasearchengine')) {
if (scratch99_fromasearchengine()) {
INSERT YOUR CODE HERE
}
}
ashutariyal Reviewed by ashutariyal on . [Help] How to Show Ads Only to Visitors Coming from Search Engines Hello Friends, i am here to get some help from you ! I have a vbulletin forum and I want to show my forum ads only to search engine users like google, yahoo or bing... I know this is possible but i don't know how to use it so please if any one know this then please share this with me and i think many other users also will like this tooo. Here i have a code for Wordpress but not for vBulletin (If any one can convert this for vbulletin it will be highly appreciated. First, you have to Rating: 5403 Forbidden Error
-
14th Nov 2009, 03:58 PM #2MemberWebsite's:
wscripts.net damnlolscript.com lulzjet.comjust ad the function as a plugin
Go to Plugins & Products->Add New Plugin
Product:vBulletin
Hook Location:global_start
Title: "What you want" for example se ads
Plugin PHP Code :
PHP Code:function scratch99_fromasearchengine(){
$ref = $_SERVER['HTTP_REFERER'];
$SE = array('/search?', 'images.google.', 'web.info.com', 'search.', 'del.icio.us/search', 'soso.com', '/search/', '.yahoo.');
foreach ($SE as $source) {
if (strpos($ref,$source)!==false) return true;
}
return false;
}
if (function_exists('scratch99_fromasearchengine')) {
if (scratch99_fromasearchengine()) {
$se_ads='your ad';
}
}
Than go to Styles & Templates->Style Manager->Edit templates and add $se_ads where you want to show the ads
-
14th Nov 2009, 04:32 PM #3OPMember
You are awsome mate... many thanks to you....
403 Forbidden Error
Sponsored Links
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
5 Ways To Keep Visitors Coming Back
By ::superman:: in forum Webmaster DiscussionReplies: 6Last Post: 27th Apr 2012, 10:25 AM -
Percentage of traffic coming from search engines?
By Sp32 in forum General DiscussionReplies: 6Last Post: 29th May 2011, 09:19 PM -
[Selling] MP3 Search Engines. NeT Automatic search engine
By freecbc3 in forum Completed TransactionsReplies: 12Last Post: 21st May 2010, 07:13 PM -
Block Search Engines
By ACE in forum vBulletinReplies: 8Last Post: 14th Jan 2010, 04:56 AM -
URL Link In Search Engines
By .v0rtex in forum Webmaster DiscussionReplies: 1Last Post: 23rd Dec 2008, 02:16 PM
themaCreator - create posts from...
Version 3.27 released. Open older version (or...