Search Field in Header

General ShopSite user discussion
Post Reply
utz119
Posts: 49
Joined: Thu Mar 29, 2007 2:46 pm
Location: New York

Search Field in Header

Post by utz119 »

Can I add thie Search code in the Header?

<form action="[-- SHOPPING_CART_URL Base --]/productsearch.cgi?storeid=[-- STORE.ID --]" method="post" onSubmit="javascript:__utmLinkPost(this)">

<form action="[-- SHOPPING_CART_URL Base --]/productsearch.cgi?storeid=[-- STORE.ID --]" method="post">

<input type=text name="search_field" size=15>
<input type=hidden name="storeid" value="[-- STORE.ID --]">
<input type=submit value="[-- STORE.177 --]">
</form>

If this code is not suitable for the Header, is there any search code to use in the header?

Thank you
Tina
Jim
Site Admin
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Post by Jim »

By "header" do you mean the one under Preferences > Header/Footer? If so the answer is no. That section is just added to the html for the page with no processing for ShopSite template tags.

But that code could could be put in an include file that is read and inserted into the html of the page when the store is published. You would then use an [-- include <filename> process --] syntax in your template to include the code.

You could also copy the html for the search field (from a page that ShopSite generated one on) and place that directly into the header and it would work.
utz119
Posts: 49
Joined: Thu Mar 29, 2007 2:46 pm
Location: New York

HTML for the search filed

Post by utz119 »

>> You could also copy the html for the search field (from a page that ShopSite generated one on) and place that directly into the header and it would work.

Where can I get this HTML for the search filed?
utz119
Posts: 49
Joined: Thu Mar 29, 2007 2:46 pm
Location: New York

Post by utz119 »

Thank you. I got it.

I just needed to view and copy the code off the site.
Post Reply