Gallery search on other website pages

TAZattitude

Joined: 2009-04-27
Posts: 74
Posted: Sun, 2013-05-26 19:42

What would the code be to add a 'gallery search' on the other pages of a website?
Meaning to add take the same search field that is in the gallery and put it elswhere on a website.

I did this with the g2 search, but can't figure out the code for g3.

Thank you

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Sun, 2013-05-26 21:45

Here is the code for a search box and go button:

<form action="http://EXAMPLE.COM/gallery3/index.php/search" id="gQuickSearchForm">
  <ul>
    <li>
      <label for="gSearch">Search the gallery</label>
      <input type="text" name="q" id="gSearch"/>
    </li>
    <li>

      <input type="submit" value="Go" />
    </li>
  </ul>
</form>

You will have to style it as you like &/or remove the <ul> and <li>s

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
TAZattitude

Joined: 2009-04-27
Posts: 74
Posted: Mon, 2013-05-27 11:15

Thanks Dave!!!

 
TAZattitude

Joined: 2009-04-27
Posts: 74
Posted: Mon, 2013-05-27 11:34

Well, thought it would work.
I changed the URL to be my website, did a search and it comes up blank.

I noticed on the search within the gallery, it mentions custom fields.
I put this code on my website, and this also comes up blank

<form action="http://www.Mywebsite.com/gallery3/index.php/custom_fields" class="g-short-form" id="g-quick-search-form">
	<ul>
		<li>
			<label for="g-search">Search the gallery (with custom fields)</label> <input class="text" id="g-search" name="q" type="text" /></li>
		<li>
			<input class="submit" type="submit" value="Go" /></li>
	</ul>
</form>

Any ideas? Thanks

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Mon, 2013-05-27 14:16

The custom fields module replaces the default search. I have never used the custom fields module so can't comment.
You should be able to just view the source on the page and copy that from to the new page adjusting the url as needed.

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team