Forums

Is the CF "OnSubmit" code executed when editing a record?

fhe 18 Jan, 2010
Hi everyone!

I've got a question. When a CF is linked to a CC for editing records, is its OnSubmit code executed?
i.e. a user defined CF OnSubmit code is executed when editing a record?

Thanks in advance
GreyHead 18 Jan, 2010
Hi fhe,

Don't know - it should be, a quick test will confirm.

Bob
fhe 19 Jan, 2010
In my opinion, for what I can see this code is not executed...is there a way to do so?
GreyHead 19 Jan, 2010
Hi fhe,

Is this OnSubmit Before Email code?? if so then 'Send Emails' needs to be set to Yes in the General tab. Just occurred to me that this might be the problem???

Bob
fhe 19 Jan, 2010
I've tried to set the Send Emails flag to 'Yes' in the General Tab but I can say that the code is not executed. Is there a way to debug what happens on the CF submit in order to see what code is executed and what code is not?
GreyHead 19 Jan, 2010
Hi fhe,

I'm afraid only by adding echo "XXX"; to the code all over the place and trying to track through :-(

Bob
ashishb01 29 Jun, 2010

Finally, it worked! I had to debug through a db field but finally I got a bull's eye!!! 😀

Many thanks Bob!

PS: [OT] Have you got any news about this issue? http://www.chronoengine.com/forums.html?cont=posts&f=12&t=16402



Can you please share the solution with me. Even I want the OnSubmit code to fire because its calling a script but am not able to. It will be great help. And about the Send Emails you are talking about CF's general tab right?? cos i dont see any email options in CC.

I have the following settings in CF: Email Results:Yes, Data Storage Yes before Sending email and onSubmit code after sending email. I also have the confirmation page plugin enabled. The form is working fine and so is CC. But upon edit in CC, neither am I seeing the confirm page, nor any email sent nor even the onSubmit execution. Can u point the problem?
PS: I am using the same form to fetch and update the CF data
This topic is locked and no more replies can be posted.