Wordpress SEO - What are you looking for?

If you're looking for answers to SEO or wordpress related questions, type in a phrase and wait for hints or click enter! The results also show links to external sources.

161 articles in the database

How to display ads only for users from search engine

[ Article content is protected by Plagiashield ]

From research conducted via SEO specialists have concluded that users coming to our pagesusers from SERPs are more likely to click on your ad than users from other sources. In this article I will show how to display ads only for them.

1. The first thing, of course, is to add new code to functions.php file in our template

$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) {
    setcookie('sevisitor', 1, time()+3600, '/', ".seowordpress.pl");
function from_searchengine(){
  global $sevisitor;
  if ($sevisitor==true || $_COOKIE["sevisitor"]==1) {
    return true;
  return false;

Please note that in the 5th line of the code there is address url websitesthat you need to change into your own.

2. Now we need to determine where We want our code to be displayed. It will probably be placed in sidebar (side part) or header (top part). In presented below code we can display not only advertisement but also e.g. welcome message, discount coupon etc.

    Paste the ad code here.

If you have defined widgets in your template it is a good idea to use plugs to display the code PHP Code Widget. We will then get an easy way to control the code through the WP panel.

Wojciech Wladzinski

O Wojciech Wladzinski

I have been dealing with SEO industry since 2008. At co day senior SEO specialist in the company Seogroup. I create and optimize large websites like and smaller websites. I am particularly fond of the environment WordPresswhich, despite popular belief, is not just a blogging platform.
  • Internal Links and Sematics

  • Link building
  • Sematics
  • Link building has never been easier. Hundreds of link possibilities in one click.
  • See

[ Article content is protected by Plagiashield ]

SEMRush - the best tool for SEO and PPC.

Read previous post:
How to disable WP automatic update?

As probably most of you, today I got a message about the automatic upgrade of wordpress to version 3.8.3. You might think, cool. But what...