coppermine-gallery.com/forum

Support => Older/other versions => cpg1.1.X Support (standalone) => Topic started by: Steve.H on October 14, 2003, 05:09:02 PM

Title: Activate Search @ Own Theme.
Post by: Steve.H on October 14, 2003, 05:09:02 PM
Hi all!

I Just edited my new site, and i created a new field for SEARCH at mains page. But i don't known how do I put it to work...  :(  

I've just coppied the SEARCH.PHP "META, Values, Etc..." into my INDEX page (where the new SEARCH BOX is avaliable)... and it still doesn't work.

Can someone in here help me how to edit it?
Thanks!
Title: Activate Search @ Own Theme.
Post by: Tarique Sani on October 14, 2003, 05:12:14 PM
URL?
Title: Activate Search @ Own Theme.
Post by: Steve.H on October 14, 2003, 05:55:23 PM
Is that Ok if I PM you Tarique?

I wouldn't like to make my URL becoming public.

 :lol:
Title: Activate Search @ Own Theme.
Post by: Tarique Sani on October 14, 2003, 05:59:31 PM
ok - PM me
Title: Activate Search @ Own Theme.
Post by: Joachim Müller on October 15, 2003, 12:08:24 AM
I'm not sure if I got your question right - to add a search box, try<form method="get" action="http://yoursite.com/coppermine/thumbnails.php" name="search_cpg">
<input type="hidden" name="album" value="search" />
<input type="hidden" name="type" value="full" />
<input type="input" name="search" maxlength="255" size="18" value="search the gallery" onfocus="this.value=''" /></form>
GauGau
Title: Activate Search @ Own Theme.
Post by: Steve on October 15, 2003, 05:55:40 AM
GauGau

Thx. the code that tarique gave me (thru PM) was correct.
But i got a "strange" issue... may I PM you my URL, so you might check it out?

I got the same code that Tarique gave me, one I inserted inside my main TABLE at index.htm
And the other one (exactly the same) i posted out of the table, right under (last line) of my template.

The one inside the TABLE returns as: NO MATCHES FOUND
But the other one (above) returns fine results.

I just don't know what's happening, since both has the same code.

Thanks in advance.
Title: Activate Search @ Own Theme.
Post by: Joachim Müller on October 15, 2003, 08:48:36 AM
sure, go ahead and pm me your url (preferably with a link to this thread as well - I often don't find the posts people refer to in pms). Maybe you've got a naming conflict of the forms: the forms mustn't have the same names...

GauGau

P.S. You could have asked to have your name changed instead of re-registering :wink:
Title: Activate Search @ Own Theme.
Post by: Joachim Müller on October 15, 2003, 08:58:55 PM
you mustn't touch the hidden fields - they don't have to be uniquely named (they're in different forms)!

Here are your forms:
a) the form that doesn't work<form method="get" action="thumbnails.php">
  <font color="#FF0000">WHY THE SEARCH DOESN'T WORKS HERE?</font>
  <input type="hidden" name="album2" value="search">
  <input type="hidden" name="type2" value="full">
  <input type="input" name="search2" maxlength="255" value="Procure uma foto" class="textinput">
  <input name="submit" type="submit" class="button" value="Ok">
</form>

b) the form that works<form method="get" action="thumbnails.php">
  <div align="center">
    <p><font color="#000099">THE SEACH BOX HERE WORKS</font> <font color="#000066">BUT
      I WISH THIS COULD WORK UP THERE</font>
<input type="hidden" name="album" value="search">
      <input type="hidden" name="type" value="full">
      <input type="input" name="search" maxlength="255" value="Procure uma foto" class="textinput">
      <input type="submit" value="Ok" class="button">
    </p>
    <p>IF THIS CODE COULD WORK UP THERE, I WOULD REMOVE THIS ONE HERE.</p>
    <p>&nbsp;</p>
  </div>
</form>


-------------------------------------------------
Here's what you do:
1) comment out the form at the bottom (put <!-- in front of it, --> after it)
2) Change to form at the top to<form method="get" action="thumbnails.php" name="searchgal">
<input type="hidden" name="album" value="search" />
      <input type="hidden" name="type" value="full" />
      <input type="input" name="search" maxlength="255" value="Procure uma foto" class="textinput" />
      <input type="submit" name="submit" value="Ok" class="button" />
</form>

3) report if this works for you

GauGau
Title: Activate Search @ Own Theme.
Post by: Steve on October 15, 2003, 09:18:19 PM
Ok, PM sent (this morning), and by the way...
I didn't knew that i could ask to change my nickname, heh.

Better, i already ask for so many support feeds in here, that i would be 'embarassed' by asking this... well, i guess now you guys may "delete" my older nick (oZmosis), hehe.

Thanks.
Title: Activate Search @ Own Theme.
Post by: Joachim Müller on October 15, 2003, 09:47:15 PM
did my suggestions work?

GauGau
Title: Activate Search @ Own Theme.
Post by: Steve on October 15, 2003, 09:49:19 PM
Woohoo!

Thanks GauGau!  :lol:
It works GREAT right now, i'll "study" the modifications that you made for me, and try to understand it a bit more.

Thanks again for you support!