Solved

Problem with page refresh

Posted on 2000-03-14
13
165 Views
Last Modified: 2013-12-24
I am passing variables in to my page using the url variable. When I refresh the page manually (F5) this works fine but when the page refreshes using the meta refresh the variables are not passed and the page is blank.I have tried putting <cfoutput> tags round the meta refresh but it produces an error.

This is the meta refresh:
<meta http-equiv="Refresh" content="240;url=http://server/frame_sets/Customers.cfm?Router=#url.Router#&TimeSpan=#url.TimeSpan#">

When the page is first called, the variables are passed from a Form on the previous page.
0
Comment
Question by:nido
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
  • 3
  • +2
13 Comments
 
LVL 37

Expert Comment

by:meverest
ID: 2615411
can you verify that the url appears correctly in the browser location field and that the meta tag is properly wrapped in cfoutput?

cheers.
0
 

Author Comment

by:nido
ID: 2615570
If I put <cfoutput> tags round the meta refresh I get the following error:

An error occurred while evaluating the expression: #url.Router#

What do you mean by 'browser location field'?
0
 
LVL 1

Expert Comment

by:bigbadb
ID: 2615683
so when you refresh the page the first time you should use form.router not url.router  It may be easy to just drop the prefix that way you can just set router = #router# on the refresh.  Try this
0
Simple, centralized multimedia control

Watch and learn to see how ATEN provided an easy and effective way for three jointly-owned pubs to control the 60 televisions located across their three venues utilizing the ATEN Control System, Modular Matrix Switch and HDBaseT extenders.

 

Expert Comment

by:samphi
ID: 2615797
Hi,

If your uses type "POST" change your URL for FORM, for the variable ROUTER.

But if "GET" uses URL.

Yes, bigbadb "just set router = #router#" works.

Attention, don't uses spaces on your variables. (replaces by %20)

Hope that help.

0
 
LVL 1

Expert Comment

by:bigbadb
ID: 2616233
samhi

Thanks for basically restating my comment as an answer

0
 

Author Comment

by:nido
ID: 2616248
I have tried dropping the url and passing #Router# as well as using #form.router# but neither work. Any idea why it won't accept the <cfoutput> tags?
0
 
LVL 1

Expert Comment

by:bigbadb
ID: 2616387
it works with the cfoutput tags or not
0
 

Author Comment

by:nido
ID: 2616427
I'm still getting a blank page when dropping the url:

<meta http-equiv="Refresh" content="240;url=http://server/frame_sets/Customers.cfm?Router=#Router#&TimeSpan=#TimeSpan#">
0
 
LVL 5

Expert Comment

by:nathans
ID: 2617179
What are you trying to this for exactly?
0
 
LVL 37

Expert Comment

by:meverest
ID: 2617575
>If I put <cfoutput> tags round the meta refresh I get the following error:

that implies that you are not passing the right variables.  although using just #router# should work, try the following explicit assignment:

<cfif isdefined('url.router')>
<meta http-equiv="Refresh" content="240;url=http://server/frame_sets/Customers.cfm?Router=#url.Router#&TimeSpan=#url.TimeSpan#">
<cfelse>
<meta http-equiv="Refresh" content="240;url=http://server/frame_sets/Customers.cfm?Router=#form.Router#&TimeSpan=#form.TimeSpan#">
</cfif>

>What do you mean by 'browser location field'?

i refer to the box where you type the url into the browser - on netscape it is called 'location' on ie it is called 'address'

cheers.





0
 
LVL 37

Accepted Solution

by:
meverest earned 75 total points
ID: 2617579
oh, i should have also said to wrap it all in cfoutput...

<cfoutput>
<cfif isdefined('url.router')>
<meta http-equiv="Refresh" content="240;url=http://server/frame_sets/Customers.cfm?Router=#url.Router#&TimeSpan=#url.TimeSpan#">
<cfelse>
<meta http-equiv="Refresh" content="240;url=http://server/frame_sets/Customers.cfm?Router=#form.Router#&TimeSpan=#form.TimeSpan#">
</cfif>
</cfoutput>

cheers.
0
 

Author Comment

by:nido
ID: 2619007
meverest

I've tried your code but still get a blank page when it refreshes, it doesn't produce an error on the <cfoutput> tags though. The fields are correctly passed to the browser location field.
0
 

Author Comment

by:nido
ID: 2619127
I was forgetting to apply this code to both pages in the frame so it now works, thanks!
0

Featured Post

Get HTML5 Certified

Want to be a web developer? You'll need to know HTML. Prepare for HTML5 certification by enrolling in July's Course of the Month! It's free for Premium Members, Team Accounts, and Qualified Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: kevp75
Hey folks, 'bout time for me to come around with a little tip. Thanks to IIS 7.5 Extensions and Microsoft (well... really Windows 8, and IIS 8 I guess...), we can now prime our Application Pools, when IIS starts. Now, though it would be nice t…
Periodically we have to update or add SSL certificates for customers. Depending upon your hosting plan you may be responsible for the installation and/or key generation. In the wake of Heartbleed many sites were forced to re-key. We will concen…
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question