PDA

View Full Version : Search my website from within AMS?


ianhull
05-30-2005, 12:28 PM
Hi All I am trying to search my website from within AMS and I have done it like this.

File.OpenURL("http://www.mydomain.com/categories.php?+Input1", SW_SHOWNORMAL);


I have a button with this action onpress and I also have a input object called Input1

I would like to beable to search my website from the text entered in Input1

Can anyone please point me in the right direction?

Thank in advance.

Corey
05-30-2005, 12:49 PM
Hi, try putting this on your button, hope that helps:

HTTP.Submit("http://www.mydomain.com/categories.php", Input.GetText("Input1"), SUBMITWEB_GET, 20, 80, nil, nil);

ianhull
05-30-2005, 01:00 PM
Thank for the quick relpy Corey,

Seems I am getting an error with this one.

On Click, Line2 must be of type table.

Any ideas?

Thanks

Brett
05-30-2005, 01:06 PM
HTTP.Submit("http://www.mydomain.com/categories.php?"..Input.GetText("Input1"), SUBMITWEB_GET, 20, 80, nil, nil);

Corey
05-30-2005, 01:14 PM
Yep, sorry, my mistake. Brett's code is easier anyhow, that'll work for you... :)

ianhull
05-30-2005, 01:15 PM
Thanks Brett,

I seem to be having a bit of trouble with this one.

I am getting the same error.

On Click, Line 1: Argument 2 Must be of type table.

Is there a way of doing it if i store my Input1 in a string?

Thanks

Brett
05-30-2005, 02:08 PM
HTTP.Submit("http://www.mydomain.com/categories.php?"..Input.GetText("Input1"), {test="nothing"}, SUBMITWEB_GET, 20, 80, nil, nil);

ianhull
05-30-2005, 02:10 PM
Thanks for your help Corey, Brett :yes

Much appreciated.

I managed to do it like this.

File.OpenURL("http://www.mydomain.com/categories.php?id="..Input.GetText("Input1"), SW_SHOWNORMAL);

Would'nt of managed it without the additional ..Input.GetText Never used that one before

Thanks again Guys.

Corey
05-30-2005, 02:10 PM
That's a cool way of doing it. :yes

Presto
04-10-2006, 03:38 PM
Thank you ianhull for the post, I have been searching for some time on here and I just found this post... this is what I have been trying to do for weeks now lol thanks guys ;)