tracker issue : CF-4204034

select a category, or use search below
(searches all categories and all time range)

CFLAYOUT Tabs not posting within tab after hotfix 8 loaded

| View in Tracker

Status/Resolution/Reason: Closed/Deferred/Duplicate

Reporter/Name(from Bugbase): Eric R. / ()

Created: 02/19/2019

Components: Tags, Page Processing

Versions: 2016

Failure Type: Incorrectly functioning

Found In Build/Fixed In Build: hf-2016-00008-313934 /

Priority/Frequency: Normal / All users will encounter

Locale/System: English / Win 2012 Server x64

Vote Count: 1

Problem Description:  After loading hotfix 8, my cfforms that exist within a tabbed layout will no longer post within the tab.  This only affects Internet Explorer, Chrome works correctly.  Rolled back to hotfix 7 and the error goes away.  The actual error trapped in IE is in cfajax.js, line 235:


the error is that "Object doesn't support property or method 'startsWith'"

Steps to Reproduce:


<cflayout type="tab" name="userLayout">
	<cflayoutarea name="tab_user" title="test">
		<cfform name="tempForm" method="post" action="temp2.cfm">
			<cfinput type="text" name="field1">
			<cfinput type="submit" name="submitButton">

<cfdump var="#form#">

Actual Result:
form dump is displayed, but in blank window
Expected Result:
form dump is displayed, but inside of "tab_user" tab
Any Workarounds:
Use Chrome or roll back to hotfix 7



I should have mentioned that this is a problem in Internet Explorer 11. As a workaround, I reverted the \scripts\ajax\package\cfajax.js file to the hotfix 7 version and it worked. I'm guessing I could comment out the if{} block in the hotfix 8 file that calls .startsWith() and that would fix it. Not sure what other impacts that might have though.
Comment by Eric R.
30349 | February 20, 2019 01:46:26 PM GMT
+1 - Please fix!
Vote by Aaron N.
30359 | February 21, 2019 07:45:39 AM GMT
Hi Eric and Aaron, IE 11 is not supporting startsWith() method. Infact Chrome,Mozilla,Safari and Opera provide browser support for the same. As a workaround goto <cfusion_home>\wwwroot\cf_scripts\scripts\ajax\package\ and add the below snippet to cfajax.js if (!String.prototype.startsWith) { Object.defineProperty(String.prototype, 'startsWith', { value: function(search, pos) { pos = !pos || pos < 0 ? 0 : +pos; return this.substring(pos, pos + search.length) === search; } }); } Note: Closing this as duplicate of bug CF-4204031 Thanks, Manas
Comment by Manas M.
30357 | February 21, 2019 09:04:41 AM GMT
Hi Manas, Wow, thank you very much for the fast workaround! Thanks!, -Aaron
Comment by Aaron N.
30358 | February 21, 2019 09:25:41 AM GMT
Could we get this code block added to the official codebase? After loading hotfix 9 and 10, I had to go in and manually add this line back. Surely CF isn't taking the stance of not supporting IE 11?
Comment by Eric R.
30505 | March 14, 2019 01:00:53 PM GMT