ColdFusion Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreColdFusion Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old April 12th, 2005, 01:05 AM
Alas's Avatar
Alas Alas is offline
Wickedwd.com
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2004
Location: wickedwd.com
Posts: 186 Alas Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 17 h 22 m 55 sec
Reputation Power: 0
Thumbs up Heres how-CFLOCATION and Target="_top"

came across this problem had a page in an inline frame that had to cflocate to another page problem was the new page didnt fit in the iframe so i had to add the target="_top" so that the page being cflocated to replaced the entire page.

THIS IS IMPOSSIBLE with CFLOCATION

heres how you do it.

Code:
<SCRIPT language="JavaScript"> top.location.replace("http://www.yourpage.com");  </SCRIPT>


If you want to just relocate without the target erase top and use location.replace

the person who uses this will probably do so in like 3 years when he runs a search here. oh well

Reply With Quote
  #2  
Old April 12th, 2005, 11:16 AM
bocmaxima's Avatar
bocmaxima bocmaxima is offline
Contributing User
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Aug 2004
Location: Tucson, Sonora
Posts: 1,322 bocmaxima User rank is Sergeant (500 - 2000 Reputation Level)bocmaxima User rank is Sergeant (500 - 2000 Reputation Level)bocmaxima User rank is Sergeant (500 - 2000 Reputation Level)bocmaxima User rank is Sergeant (500 - 2000 Reputation Level)bocmaxima User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 3 Days 17 h 46 m 5 sec
Reputation Power: 22
Send a message via AIM to bocmaxima
ColdFusion = Server
JavaScript = Client

In other words, <cflocation> in no way equals window.location!

The target attribute is in reference to the client's browser and cannot be manipulated in any way by a server-side language. People take CF's versatility for granted too often, I think.

Reply With Quote
  #3  
Old April 12th, 2005, 02:26 PM
kiteless kiteless is offline
Moderator
Dev Shed Expert (3500 - 3999 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 3,627 kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 10 h 8 m 55 sec
Reputation Power: 53
Exactly. CFLOCATION executes an HTTP redirect. The server has no idea what "_top" is on the client's machine, it simply executes another HTTP request.
__________________
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

Reply With Quote
  #4  
Old April 12th, 2005, 04:52 PM
Alas's Avatar
Alas Alas is offline
Wickedwd.com
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2004
Location: wickedwd.com
Posts: 186 Alas Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 17 h 22 m 55 sec
Reputation Power: 0
umm *cough* bocmaxima dont want to make you feel crunchy but did you not read that i wrote "THIS IS IMPOSSIBLE with CFLOCATION" hence you should take the next logical step of utilizing brain power to see that i offer a javascript as a workaround to cflocation not being able to target since Yes it is server and Yes javascript is client. Gosh a little reading goes a long way

PS. et tu kiteless? had to jump me too.


Quote:
Originally Posted by bocmaxima
ColdFusion = Server
JavaScript = Client

In other words, <cflocation> in no way equals window.location!

The target attribute is in reference to the client's browser and cannot be manipulated in any way by a server-side language. People take CF's versatility for granted too often, I think.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreColdFusion Development > Heres how-CFLOCATION and Target="_top"


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway