Posting to self and getting data from a text field


Hi there
I have a web page which, at present, list the last 5 tweets about a search term in a div tag.

I want the user of the web page to be able to enter a different term in a text field, click submit and the div will refresh with the new tweets.
How do you get the form to change a variable and then refresh the div?
POST_SELF didnt seem to work but never used this before so was probably something I was doing wrong.

I can provide code if needed, please ask.


can you post the code please


Are you outputting your

with php?

echo(’ Your new search has been successful’);
//output from $_POST variable
//output from $_GET variable

Depending on how your search is done with $_POST from the search form or $_GET from the original search it will change.
As long as you use the same form names you wont have do anything to update the search, unless you want to give the user a success message.