Hello Everyone,
Let me preface this by saying I am completely new to ShopSite and working through my first storefront.
The store in question can be found at: http://brotherscountrysupply.com/store/
I am having a hard time finding specifics in the forum, so I hope it's ok that I'm posting new topics.
I have ShopSite Pro and a LAMP stack for this store:
First off - are ShopSite tags case sensitive?
Secondly - how do I go about adding in the search functionality to my layout in the two search fields I have set up?
The little magnifying glass is an image but I will use it as the submit button. I usually use Javascript to submit forms with this method - will this cause any issues with ShopSite?
Thanks very much!
Creating a Search Field
-
- Posts: 84
- Joined: Tue Dec 06, 2011 4:18 pm
- Location: Earlville - the land of Earls
- Contact:
Creating a Search Field
Website Design, Website Development, eCommerce and Hosting
-
- Site Admin
- Posts: 4953
- Joined: Fri Aug 04, 2006 1:42 pm
- Location: Utah
Re: Creating a Search Field
1. ShopSite template tags are not case sensitive. However if you use an IF statement the comparison values are, for example
[-- VAR.word Jim --}
[-- IF VAR.word Jim --] will be true but [-- IF VAR.word jim --] would be false.
2. There is a template tag [-- SEARCH_FORM --] that outputs the search form. You can change the button used for searching to the magnify image on Preferences > Store Text > Store Pages in the Search: field. There are also styles assigned to the form so you can add classes to your css and use that to change the look.
Another way to get the search field form is to create a page in ShopSite, check the box to have a search form on the page, publish and then view the source of the page and copy the <form... to </form> and you can put that code in your template or in the html of a page created outside of ShopSite.
Using Javascript to submit forms is fine as long as you do it properly. However, I have seen many sites that do not use it properly and have problems.
[-- VAR.word Jim --}
[-- IF VAR.word Jim --] will be true but [-- IF VAR.word jim --] would be false.
2. There is a template tag [-- SEARCH_FORM --] that outputs the search form. You can change the button used for searching to the magnify image on Preferences > Store Text > Store Pages in the Search: field. There are also styles assigned to the form so you can add classes to your css and use that to change the look.
Another way to get the search field form is to create a page in ShopSite, check the box to have a search form on the page, publish and then view the source of the page and copy the <form... to </form> and you can put that code in your template or in the html of a page created outside of ShopSite.
Using Javascript to submit forms is fine as long as you do it properly. However, I have seen many sites that do not use it properly and have problems.
-
- Posts: 84
- Joined: Tue Dec 06, 2011 4:18 pm
- Location: Earlville - the land of Earls
- Contact:
Re: Creating a Search Field
OH oh oh oh, ok it looks like the copy/paste HTML option is going to be desirable for my layout.
http://brotherscountrysupply.com/store/
I will try this tonight and see if I can style it properly. If I can, and then just make it an include, this would be perfect.
Thanks very much!!!
http://brotherscountrysupply.com/store/
I will try this tonight and see if I can style it properly. If I can, and then just make it an include, this would be perfect.
Thanks very much!!!
Website Design, Website Development, eCommerce and Hosting