I have a text box on my page and a submit button. The text box value is whatever it 
grabs from the database. If the user deletes what is in the text box and puts in his 
own text, then hits submit, the script updates that field with whatever the user 
inputs. 

Problem is, after the user hits submit, it APPEARS as though the new text was not 
submitted because the old text is still in the box. Yet when he refreshes the page it 
shows the new text. 

Does that make sense? How do I make it so the new text shows up without him having to 
refresh. Also I don't want to do a redirect because I want to print a message "Info 
submitted" when the user hits submit. 

I have tried: 

function cache_control($maxage=0) { 
$Modified = "Last-modified: ".gmdate("D, d M Y H:i:s", time())." GMT"; 
$Expires = "Expires: ".gmdate("D, d M Y H:i:s", time() + $maxage)." GMT"; 
$CacheControl = "Cache-Control: must-revalidate, max-age=".$maxage.", "; 
$CacheControl.= "s-max-age=".$maxage; 
Header($CacheControl); 
Header($Modified); 
Header($Expires); 
} 

cache_control(0); 


Thanks so much for reading, 
Nate

Reply via email to