|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
|
|
#1
|
|||
|
|||
|
for the last several days, i am encountering this weird problem. i use <cfmail> to send an email which includes a link to a form. when the user launches the form from this email, the form looks up a database and populates the fields and displays it. my problem is even if the fields are changed (db is updated) the form won't display the correct values unless i hit 'refresh' on the menu bar. is there a way to force the page to refresh itself just once?
i have a similar problem where i update a table and then go back one page to see the new values in a select list. the same thing happens there too, if i don't hit refresh the values are the old values. what am i doing wrong? can anyone help? |
|
#2
|
||||
|
||||
|
The back and forward buttons won't refresh the page by default. You'll need to somehow get the user back to the form page (maybe just post the form to the form page and run the SELECT after the UPDATE) to see the new values.
If you hit the page, it should automatically load the new values because the server will always have to re-process the server-side code (there is no cache). Hope that helps. |
|
#3
|
|||
|
|||
|
You could also set a META refresh to something like 5 or 10 minutes.
<meta http-equiv=Refresh content="700;url=http://www.mysite.com/mypage.cfm"> Would redirect to that URL after 700 seconds.
__________________
Ask if you have a question, but also help answer questions that you have knowledge of! Thanks, Brian. How to Post a Question in the Forums |
|
#4
|
|||
|
|||
|
i tried using
Click<a href="myPage.cfm">here</a> to go back.. but that didn't refresh the page either. it seems like the page is cached. if i use <meta http-equiv=Refresh content="700;url=http://www.mysite.com/mypage.cfm"> wouldn't the page refresh itself every 700 seconds? i tried couple javascript functions that i found, but they caused page to go an endless loop where the page keeps refreshing itself again and again instead just once. |
|
#5
|
|||
|
|||
|
Yes the META tag would refresh it every 700 seconds. You could use CF logic to only place the META tag there once, and then omit it after the page has reloaded.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ColdFusion Development > Forcing a page to refresh |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|