Search Box on Anywhere

Search Box on Anywhere

This code can be used to install a CSS style search box anywhere on a OSCommerce shopping cart. It uses OSCommerce functions and clears when clicked on.

Paste this code where you would like to have the search box:

<div class="search-box">
 <?php echo tep_draw_form('quick_find', tep_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', 'SSL', false), 'get'); ?>
  <input type=text name="keywords" size="10" maxlength="25" class="search-field" value="Search..." onclick="this.value='';" onblur="if(!this.value) {this.value='Search...'; }">
  <input type="hidden" name="search_in_description" value="1" />
  <input type="hidden" name="inc_subcat" value="1" />
  <?php echo tep_hide_session_id() .'<input type="submit" name="search" value="" class="search-go" border="0" width="79" height="25">';?>

Add this to your style sheet:

.search-box{ /*outer background*/float:right; height: 26px; padding: 10px 10px 0px 10px; }{ /*input field */ color:#999999; float: left; border:1px dotted #CCCCCC; border-width: 1px 0px 1px 1px; margin:0; padding: 3px 0px 0px 4px; height:16px; width: 92px; } { /*search icon */ float:left; border:1px solid #CCCCCC; border-width: 1px 1px 1px 0px; margin:0; padding:0; margin-left: 0px; height: 21px; width: 21px; background: #F2F2F2 url(img/icon-search.png) no-repeat top left; cursor: pointer; }{ /*search icon hover "Does Not work in ie6" */ background:url(images/icon-search.png) no-repeat bottom left; }

Related Posts

11 thoughts on “Search Box on Anywhere

  1. plantas a domicilio

    Hi there, I found your website by means of Google even as searching for a related subject, your website got here up, it appears to be like good. I’ve added to my favourites|added to bookmarks.

  2. Mickey Dales

    Great write-up, I’m regular visitor of one’s website, maintain up the nice operate, and It’s going to be a regular visitor for a long time.

  3. getiton

    I do agree with all the concepts you’ve offered for your post. They’re really convincing and can certainly work. Nonetheless, the posts are too short for starters. May you please prolong them a bit from subsequent time? Thank you for the post.

  4. Top ten

    Hello there, just became aware of your weblog through Google, and found that it is really informative. I’m gonna watch out for brussels. I’ll be grateful when you continue this in future. Lots of folks might be benefited out of your writing. Cheers!

  5. Elmer Rafla

    I simply want to tell you that I am just newbie to weblog and honestly loved your web page. Probably I’m likely to bookmark your site . You definitely come with perfect article content. Thanks a bunch for revealing your web page.

  6. Otha Yokoyama

    I just want to mention I’m all new to blogs and certainly enjoyed your website. Very likely I’m want to bookmark your site . You certainly have fantastic articles and reviews. Bless you for sharing with us your web page.

  7. barato

    Fantastic points altogether, you simply received a logo new reader. What would you suggest in regards to your publish that you simply made a few days ago? Any positive?

  8. paseo maritimo

    My brother suggested I might like this website. He was totally right. This submit actually made my day. You can not consider just how much time I had spent for this information! Thank you!

  9. seo software

    Hello my family member! I wish to say that this post is awesome, great written and include almost all important infos. I’d like to peer more posts like this .

  10. Ismael Hongeva

    I simply want to mention I am just newbie to blogging and site-building and certainly loved this web-site. Likely I’m planning to bookmark your site . You surely come with really good article content. Kudos for sharing your webpage.


Leave a Reply

Your email address will not be published. Required fields are marked *