Would like some help with sphider search...

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
mantisinc
Forum Newbie
Posts: 3
Joined: Sun Mar 11, 2007 1:30 pm

Would like some help with sphider search...

Post by mantisinc »

Hello all,

First time on this forum, very nice I have to say
Okay, I am having a little bit of trouble with sphider search box. I have installed it okay, and it is working great. Have got a search box globally on the website, and all is good.
However, what I would like to do, is put a search box on an external site, that when a query is entered and searched, it will search on the sphider search at the initial website.
So, here is an example.
Sphider search is installed on the website 321.com. And I have got a search box on 654.com which links directly to search the engine on 321.com.
So, if I was to do a search on 645.com, it would link okay to the search, but there would be an error in the URL. Say if I searched "cheese":

http://www.321.com/search.php?query2=cheese&search2=1

It would look like this. But, the "2" after "query" and the "2" after "search" should not be there...and with the extra 2 in the URL, it just returns a blank result.
It should look like this:

http://www.321.com/search.php?query=cheese&search=1

It is very wierd. If entering a query on 321.com it returns the result with the right URL, with no mysterious "2"s in the URL, but when entering a query from an external site, these "2"s appear.

Why is this happening, and what can I do to stop this?

Thanks in advance!
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Can you post the code that generates the form being interacted with?
User avatar
louie35
Forum Contributor
Posts: 144
Joined: Fri Jan 26, 2007 8:40 am
Location: Dublin
Contact:

Post by louie35 »

it looks like your program automatically assigned "search2" in the name for the second button or whatever you have in the form as input type, as it already exist on the page.
can you not change the name of the input?
mantisinc
Forum Newbie
Posts: 3
Joined: Sun Mar 11, 2007 1:30 pm

Post by mantisinc »

Sure....do you mean the code that generates the form on the external site?
mantisinc
Forum Newbie
Posts: 3
Joined: Sun Mar 11, 2007 1:30 pm

Post by mantisinc »

Oh god, what a tit I am...it physically had the number 2 in the form code.
I have been pulling my hair out for ages over this!!!
Thanks anyway guys ;)
Post Reply