Skip to main content
added 1 characters in body
Source Link
s_ha_dum
  • 65.5k
  • 13
  • 84
  • 174

You want is_front_page

if (!is_front_page()) { ?>
  <!-- BEGIN TOP SEARCH -->

    <form id="searchform" action="<?php bloginfo('url'); ?>/" method="get">
      <input type="submit" value="" id="searchsubmit"/>
      <input type="text" class="field" name="s" id="s" value="Search or be lost" onfocus="this.value=''" />
    </form>
  </div>
  <!-- END TOP SEARCH --><?php
}

Take a look at the list of Conditional Tags. It is all in the Codex.

By the way, there is a stray </div>. That may be why this markup doesn't work the way expect.

You want is_front_page

if (is_front_page()) { ?>
  <!-- BEGIN TOP SEARCH -->

    <form id="searchform" action="<?php bloginfo('url'); ?>/" method="get">
      <input type="submit" value="" id="searchsubmit"/>
      <input type="text" class="field" name="s" id="s" value="Search or be lost" onfocus="this.value=''" />
    </form>
  </div>
  <!-- END TOP SEARCH --><?php
}

Take a look at the list of Conditional Tags. It is all in the Codex.

By the way, there is a stray </div>. That may be why this markup doesn't work the way expect.

You want is_front_page

if (!is_front_page()) { ?>
  <!-- BEGIN TOP SEARCH -->

    <form id="searchform" action="<?php bloginfo('url'); ?>/" method="get">
      <input type="submit" value="" id="searchsubmit"/>
      <input type="text" class="field" name="s" id="s" value="Search or be lost" onfocus="this.value=''" />
    </form>
  </div>
  <!-- END TOP SEARCH --><?php
}

Take a look at the list of Conditional Tags. It is all in the Codex.

By the way, there is a stray </div>. That may be why this markup doesn't work the way expect.

Source Link
s_ha_dum
  • 65.5k
  • 13
  • 84
  • 174

You want is_front_page

if (is_front_page()) { ?>
  <!-- BEGIN TOP SEARCH -->

    <form id="searchform" action="<?php bloginfo('url'); ?>/" method="get">
      <input type="submit" value="" id="searchsubmit"/>
      <input type="text" class="field" name="s" id="s" value="Search or be lost" onfocus="this.value=''" />
    </form>
  </div>
  <!-- END TOP SEARCH --><?php
}

Take a look at the list of Conditional Tags. It is all in the Codex.

By the way, there is a stray </div>. That may be why this markup doesn't work the way expect.