PHP Display a search result from MySQL Search -


i have 3 php pages:

  1. search.php sets out form fields used query mysql database
  2. query.php queries database variables set in search.php, , return result array (which can large array), redirect result.php
  3. result.php , display results in table form. page not connected database, , page bookmarkable, ie if bookmarks page, display result again without quering database.

my problem don't know how make result page bookmarkable.. used session carry variable query.php result.php once browser closed, result page display nothing.

if can help, highly appreciated.

1. bookmarks:
know, browser bookmarks save link page, wise use $_get[] variables fields in form every time 1 visits page, server know search parameters automatically url
eg.

$search = $_get["s"] //query database parameter $search  

they bookmark link this:
www.example.com/result.php?s=snoopy
server know "snoopy" search term.

2. saving data

"if bookmarks page, display result again without quering database."

unless planning download information, don't think there way load data without querying database again. bet there's convoluted way hidden somewhere in browser cookies or that... don't think it's worth going far though.


Comments

Popular posts from this blog

OpenCV OpenCL: Convert Mat to Bitmap in JNI Layer for Android -

android - org.xmlpull.v1.XmlPullParserException: expected: START_TAG {http://schemas.xmlsoap.org/soap/envelope/}Envelope -

python - How to remove the Xframe Options header in django? -