I dont have the code here at home, but this is a kind of requirement  
for a modal window... i.e. a window that stops the window below it  
from gaining focus until its closed.

I have seen it implemented as a modal popup but you could also  
implement it as a div that covers the main window (I have done this  
and can try and find the code.

Basically it puts a div over EVERYTHING on the window (thus you cant  
gain access to any of the links or functions) and presents you with a  
popup that you have to close or submit so that it will go away.

Would either of these help?

Regards

Mark Drew

On 29 Jan 2006, at 22:04, Eric Roberts wrote:

> I will have to try that...thanks!
>
> Eric
>
> -----Original Message-----
> From: Adrian Lynch [mailto:[EMAIL PROTECTED]
> Sent: Sunday, 29 January 2006 15:32
> To: CF-Talk
> Subject: RE: Javascript question...or suggestion where to go to get  
> answer
>
> Only tested on IE6:
>
> Two pages, temp.cfm and temp2.cfm
>
> temp.cfm:
>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
>
> <html>
> <head>
>       <title>Untitled</title>
>       <script type="text/javascript">
>
>               function pageLoaded() {
>
>                       window.onfocus = function() {
>                               alert("WE HAVE FOCUS");
>                       };
>
>                       window.onblur = function() {
>                               window.close();
>                       };
>
>               }
>
>       </script>
> </head>
>
> <body onload="pageLoaded();">
>
> </body>
>
> </html>
>
>
> temp2.cfm
>
> <script>
>       window.open("temp.cfm", "aNewWindow");
> </script>
>
>
> Seems to work but I'd test a fair bit :O)
>
> Adrian Lynch
> http://www.halestorm.co.uk/
>
> Spring clean out:
> http://www.adrianlynch.co.uk/selling/
>
> -----Original Message-----
> From: Eric Roberts [mailto:[EMAIL PROTECTED]
> Sent: 29 January 2006 21:11
> To: CF-Talk
> Subject: OT: Javascript question...or suggestion where to go to get  
> answer
>
>
> I have a JavaScript dilemma in one of my CF apps and I am not sure  
> how to
> solve it.  We have popup that is used to modify some values in the  
> database
> before running a report.  We want this popup to close if you click on
> another window.  I tried putting close in an onBlur event as part  
> of the
> body tag, but then when I click on any location within the window, it
> closes...I guess because when you focus on one element, you are  
> blurring
> another.  Anyone have any suggestions on how to accomplish this or  
> where I
> can go to get some help with this?  Any help would be greatly  
> appreciated.
>
> Blessings,
> Eric
>
>
>
>
>
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:230710
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to