Solved

window location coldfusion passing

Posted on 2007-11-26
10
978 Views
Last Modified: 2012-05-05
I am getting an error that says, expected ) when I try this, why?

opener.location.href('calendar.cfm?Qdate=#dateformat(form.appdate, 'mm/dd/yyyy')#'); window.close();
0
Comment
Question by:judsonmusic
  • 5
  • 4
10 Comments
 
LVL 14

Expert Comment

by:B_Dorsey
Comment Utility
you are opening a window and closing the window that opened the window?
0
 
LVL 52

Expert Comment

by:_agx_
Comment Utility
To set the location use = not parenthesis (...)


<cfoutput>
...
opener.location.href='calendar.cfm?Qdate=#dateformat(form.appdate, 'mm/dd/yyyy')#';window.close();
</cfoutput>
0
 
LVL 3

Author Comment

by:judsonmusic
Comment Utility
I actualy had to do this:

opener.location.href=('calendar.cfm?Qdate=#dateformat(form.appdate, 'mm/dd/yyyy')#');window.close();
0
 
LVL 52

Accepted Solution

by:
_agx_ earned 500 total points
Comment Utility
0
 
LVL 3

Author Comment

by:judsonmusic
Comment Utility
well actually, thats not working either.

this is what I put:
  <script>
  window.opener.location.href='calendar.cfm?Qdate=#dateformat(form.appdate, 'mm/dd/yyyy')#';
  window.close();
  </script>

it is now saying, expected ;
0
How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

 
LVL 3

Author Comment

by:judsonmusic
Comment Utility
what I am doing, is at the end of and update statement, I want to colse the currentpopup and go back to the url in the opener window. i was using refresh, but it gives that retry error.
0
 
LVL 52

Expert Comment

by:_agx_
Comment Utility
> this is what I put:

You need to surround it with <cfoutput> tags

<script type="text/javascript">
      <cfoutput>
      opener.location.href='calendar.cfm?Qdate=#dateformat(form.appdate, 'mm/dd/yyyy')#';
      window.close();
      </cfoutput>
</script>

> i was using refresh, but it gives that retry error.

What syntax were you using..  reload()?
0
 
LVL 3

Author Comment

by:judsonmusic
Comment Utility
yes, reload, is there a better way?
0
 
LVL 52

Expert Comment

by:_agx_
Comment Utility
Reload is fine.  But I don't know what "that retry error" is.  That's why I wanted to see the syntax you used.
0
 
LVL 3

Author Comment

by:judsonmusic
Comment Utility
oh it is just IE7 warning about page reload, thats all
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Select2 jquery help 9 41
How to add loader animation to a page ? 2 19
Accessing data in JSON response.d 4 26
modify h2 4 8
Sometimes databases have MILLIONS of records and we need a way to quickly query that table to return the results me need. Sure you could use CFQUERY but it takes too long when there are millions of records. That is why SOLR was invented. Please …
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

762 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now