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

Coldfusion 2018 update 11 error

Community Beginner ,
Mar 25, 2021 Mar 25, 2021

Copy link to clipboard

Copied

After installing the update, form variables being sent as a list, cannot be read as a simple values, they are now being sent as arrays.

error message is 

 Complex object types cannot be converted to simple values

Views

1.6K

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

correct answers 1 Correct answer

Community Expert , Apr 07, 2021 Apr 07, 2021

This is a known issue. The recent March cf updates changed this. And whether it is right or wrong (that they did that), there is at least a work-around. And no, you do NOT need to hunt down every program, just every CF application (at least until perhaps Adobe may offer a JVM arg to revert things instance-wide): 

  • if using application.cfc put in this.sameformfieldsasarray="false"
  • if using application.cfm put the same attribute (as sameformfieldsasarray="false") into your cfapplication tag

 

(Up

...

Votes

Translate

Translate
Community Expert ,
Apr 20, 2021 Apr 20, 2021

Copy link to clipboard

Copied

It's not clear. Are you saying that you did add that sameformfieldsasarray="false" into your cfapplication tag in application.cfm, as I showed above. If you did, you should not get the error any more. Please clarify.


/Charlie (troubleshooter, carehart.org)

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
Community Expert ,
Apr 20, 2021 Apr 20, 2021

Copy link to clipboard

Copied

@sgean01 : ... the only CFAPPLICATION tag that exists is there.

this is a very old (and large) website that has moved up from CF10 to CF11 to CF2018.    All I can say about it is that when hotfix11 is installed, I receive that error at various places in my code...

 

As others have said, one solution is to place the attribute in the tag:

<cfapplication sameFormFieldAsArray="false" etc. >

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
Community Expert ,
Apr 21, 2021 Apr 21, 2021

Copy link to clipboard

Copied

Ah, Shawn. There is now an explanation for why it didn't work for you. The attribute is sameformfieldsasarray (with an s after field). I was mistaken in my first reply to this thread a couple weeks ago, and we only came to realize the mistake thanks to a comment here from Benjamin.

 

I've corrected my first reply and added a reply thanking him, with apologies to all. 


/Charlie (troubleshooter, carehart.org)

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
Community Expert ,
Nov 03, 2021 Nov 03, 2021

Copy link to clipboard

Copied

LATEST

As an update on all this, and an FYI to those who maybe didn't notice: update 12 (of CF2018) and update 2 (of cf2021) did revert the behavior back to defaulting sameformfieldsasarray to false.


/Charlie (troubleshooter, carehart.org)

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