• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

initiate javascript in coldfusion

LEGEND ,
Oct 09, 2006 Oct 09, 2006

Copy link to clipboard

Copied

I am trying to modify an exisiting javascript applicaion. One of the parts
in manually entering the url for an image. I would like to change that from
manually to allowing for an image to be uploaded. The form is set to:

<form action="#" enctype="multipart/form-data"
onSubmit="insertAction();return false;">

I would like to set up a code block to first upload the image, then set the
formObj.scr to a set value plus the image that was uploaded.

I have this:

<cfif IsDefined ('insert')>
<cffile action="upload" destination="E:\www\mailings\images"
nameconflict="makeunique" filefield="src" >
<cfset src = " http://www.mywebsite.com/mailings/images/#cfile.serverFile#">
</cfif>

From there I want to then initiate the Javacript (insertAction();return
false)that will finish the routine and insert it into my html WYSIWYG.

I have searched google and could not find any ideas.

Is this possible?


TOPICS
Advanced techniques

Views

215

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Oct 09, 2006 Oct 09, 2006

Copy link to clipboard

Copied

LATEST
Nevermind. Figured it out.


Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation