Solved

window location coldfusion passing

Posted on 2007-11-26
10
1,028 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
[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
  • 4
10 Comments
 
LVL 14

Expert Comment

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

Expert Comment

by:_agx_
ID: 20353802
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
ID: 20357830
I actualy had to do this:

opener.location.href=('calendar.cfm?Qdate=#dateformat(form.appdate, 'mm/dd/yyyy')#');window.close();
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 52

Accepted Solution

by:
_agx_ earned 500 total points
ID: 20357885
0
 
LVL 3

Author Comment

by:judsonmusic
ID: 20357897
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
 
LVL 3

Author Comment

by:judsonmusic
ID: 20357904
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_
ID: 20357962
> 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
ID: 20358471
yes, reload, is there a better way?
0
 
LVL 52

Expert Comment

by:_agx_
ID: 20358578
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
ID: 20358593
oh it is just IE7 warning about page reload, thats all
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

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

When the s#!t hits the fan, you don’t have time to look up who’s on call, draft emails, call collaborators, or send text messages. An instant chat window is definitely the way to go, especially one like HipChat. HipChat is a true business app. An…
Q&A with Course Creator, Mark Lassoff, on the importance of HTML5 in the career of a modern-day developer.
The viewer will learn how to count occurrences of each item in an array.
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

623 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