Solved

On Change Event

Posted on 2004-03-24
6
166 Views
Last Modified: 2013-12-24
I have a form displaying several fields from a CFQuery.  The user needs the ability to edit the field.  Once the user has completed their edits and clicked outside the field text-box, I want the record to be updated on the database...  is there a OnChange event that can do this in ColdFusion?  If so do you have an example???
0
Comment
Question by:jdoub
  • 2
6 Comments
 
LVL 17

Accepted Solution

by:
Tacobell777 earned 25 total points
ID: 10673232
This is a trciky one, and I dont think you would want to do it this way.
Anyway, you could do

<input type="text" name="blah" onBlur="document.yourFormName.submit();">
0
 
LVL 17

Expert Comment

by:anandkp
ID: 10675484
I wld not recommend this logic

Its better u use a submit button for this - so user knows that if incase he mistypes something he can always go back to it & edit it - without having to bother abt it being submitted "onBlur".

Just A Thought !

but if u want to go ahead with it - u already have the answere above.
0
 
LVL 17

Expert Comment

by:Tacobell777
ID: 10675586
Thats exactly what I said, and I quote "and I dont think you would want to do it this way"
0
 

Assisted Solution

by:tnunamak
tnunamak earned 25 total points
ID: 10934119
OnChange is a JAVASCRIPT event, which is client side.  CF is server side.  The only way you'll be able to use OnChange is to force a submit to the web server (either a hidden frame/ popup window or just a plain form submission).  The browser paradigmn is well established and users are trained to look for buttons to click on.  I would put a submit button on the page and use the browser like most users are used to using it.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

In our day to day coding, how many times have we come across a necessity to check whether a URL is a broken link or not? For those of you that answered countless and are using ColdFusion like myself, then this article is for you.  It will show yo…
When it comes to showing a 404 error page to your visitors, you do not want that generic page to show, and you especially do not want your hosting provider’s ad error page to show either. In this article, I will show you how to enable the custom 40…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

743 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now