Javascript issues in CFFORM

View: New views
2 Messages — Rating Filter:   Alert me  

Parent Message unknown Javascript issues in CFFORM

by Dan O'Keefe-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I flat out cannot get a window to pop up using <cfformitem type="html><a
href="#" onclick="window.open etc, etc etc

If I use target="_blank" it works but then you do not have the same control
over the window. Trying to get javascript to perform the same in flash forms
has been my most frustrating problem using them.

Thanks,

Dan
--------------
Dan O'Keefe

--
--------------
Dan O'Keefe


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four times a year.
http://www.fusionauthority.com/quarterly

Archive: http://www.houseoffusion.com/groups/CF-Flash/message.cfm/messageid:172
Subscription: http://www.houseoffusion.com/groups/CF-Flash/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.30

Parent Message unknown RE: Javascript issues in CFFORM

by Michael White-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

You need a function at the top like this:

<!--- Javascript routine to open new window --->
<script>
        function show(u) {
                if(u != '') window.open(u, 'sub', 'directories=no,
location=no, menubar=no, resizable=yes, scrollbars=no, status=no,
titlebar=yes, toolbar=no, height=435, width=535')
        }
</script>

Then some object in the flash form with an onclick event like a button:

                        <cfinput
                                id="Profile"
                                name="Profile"
       
onclick="getURL('javascript:show(\'/Profile.cfm'+'?ContactID='+gridActiv
ity.selectedItem.ContactID+'\')')"
                                style="fontFamily:'Trebuchet MS';
textRollOverColor:##FFFFFF;fontSize:16;color:##E1F5FA;fillColors:##334C6
6,##4C7399;"
                                type="Button"
                                value="Contact Profile"
                                visible="{gridActivity.selectedItem !=
undefined}"
                                tooltip="click this button to view this
Contact's profile information"
                                width="175"/>


Michael White
Photographer, Coldfusion developer
http://www.michaelwhitephoto.com
mwhite007@...

-----Original Message-----
From: Dan O'Keefe [mailto:dan.okeefe@...]
Sent: Tuesday, October 31, 2006 4:05 AM
To: CF-Flash
Subject: Javascript issues in CFFORM

I flat out cannot get a window to pop up using <cfformitem type="html><a
href="#" onclick="window.open etc, etc etc

If I use target="_blank" it works but then you do not have the same
control over the window. Trying to get javascript to perform the same in
flash forms has been my most frustrating problem using them.

Thanks,

Dan
--------------
Dan O'Keefe

--
--------------
Dan O'Keefe




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four times a year.
http://www.fusionauthority.com/quarterly

Archive: http://www.houseoffusion.com/groups/CF-Flash/message.cfm/messageid:175
Subscription: http://www.houseoffusion.com/groups/CF-Flash/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.30