Details
Assignee
Michael OffnerMichael OffnerReporter
Brad WoodBrad WoodLabels
New Issue warning screen
Before you create a new Issue, please post to the mailing list first https://dev.lucee.org
Once the issue has been verified, one of the Lucee team will ask you to file an issue
Priority
New
Details
Details
Assignee
Michael Offner
Michael OffnerReporter
Brad Wood
Brad WoodLabels
New Issue warning screen
Before you create a new Issue, please post to the mailing list first https://dev.lucee.org
Once the issue has been verified, one of the Lucee team will ask you to file an issue
Priority
Created 7 July 2021 at 17:57
Updated 4 August 2022 at 20:25
In Adobe ColdFusion, the cgi scope can be used to access any HTTPServetRequest Attribute. Note the following example assumes you actually have an attribute of this name set. I tested this using the error page handling of my servlet container in CommandBox. Note this ticket or behavior is not specific to CommandBox, I simply used it for an easy test,.
Setup server:
CommandBox> server set web.errorPages.404=404.cfm CommandBox> server set openBrowserURL=/sdfsdf.txt CommandBox> touch 404.cfm --open
Paste this code in the 404.cfm file.
<h1>404.cfm</h1> <cfscript> writeOutput( getPageContext().getRequest().getAttribute( 'javax.servlet.error.request_uri' ) ); writeOutput( cgi['javax.servlet.error.request_uri'] ); </cfscript>
Then start your server
CommandBox> server start
In Adobe ColdFusion, the sdfsdf.txt URI will show up twice, but in Lucee the CGI scope just outputs an empty string.