CFWINDOW and CFFORM don't like hidden form variables named "action"

I kept getting an error with a CFFORM that I was using within a CFWINDOW. The error was:

error: http: Error retrieving markup for element editWindow_body : Not Found

This error message would go away if I would use a regular HTML form tag. After a bit of searching I found the solution. I had a hidden variable in the form named "action". Such as:

<input type="hidden" name="action" value="editCompany">

It appears that the Javascript/Ajax libraries for coldFusion 8 have the form variable "action" as a reserved word, and this was conflicting with the normal operation of the page. I quickly changed the name of the hidden variable to "myAction" along with the code and everything works normally.

<input type="hidden" name="myAction" value="editCompany">

Comments (Comment Moderation is enabled. Your comment will not appear until approved.)
Mark's Gravatar Holy cow! This had been kicking my butt for a week!! I use a hidden form element of "action" in almost all my forms, but it never dawned on me to try it without that element. So glad I found this solution. Thanks!
# Posted By Mark | 4/18/08 3:10 PM
Jay Smith's Gravatar I'm using cfform and cfwindow. I do not use any hidden variables, however I'm using cfgrid, and I getting the same error - "Error retrieving markup for element editWindow_body: Object Not Found". How can I eliminate this error.
# Posted By Jay Smith | 12/16/08 10:47 AM
Brett's Gravatar Wow. I CANNOT thank you enough for this post. I've spent half my day trying to figure out this stupid issue I was having. I tried every trick in the book. Come to find out this was the issue the whole time.

You would think that the Adobe people wouldn't use a word like this as a reserved word since it seems like a fairly common use by CF programmers
# Posted By Brett | 12/31/08 2:15 PM
James's Gravatar I agree with all y'all. Thanks for posting this! Probably saved me hours of WTF.
# Posted By James | 3/3/09 11:35 PM
BlogCFC was created by Raymond Camden. This blog is running version 5.8.001.