Highlighted

ColdFusion 2018 - browser prompts to download cfm files instead of running them

New Here ,
Feb 05, 2020

Copy link to clipboard

Copied

Hi everyone,

     I have a new web server running Server 2016 and CF 2018 Standard.  No issues with install and the cfadmin site opens and runs fine.  However, the additional sites we have added will not run cfm or any of the other associated file types.  All it does is prompt for a download.  I've checked everything I can think of and still no luck.  Below is the list of what I have tried.  I'm hoping someone out there has a silver bullet for this issue.  Appreciate any help you can provide.  Thanks!

 

  • Have removed and added the web servers in the Adobe Web Server Configuration tool
  • Have removed and added the app pools associated with the web sites
  • Have checked all file permissions to make sure both the CF user and the App Pool have access
  • Have checked all CF settings with a different server (same config) that is working as expected
  • Have checked all IIS settings with a different server as well
TOPICS
Server administration

Views

600

Likes

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

ColdFusion 2018 - browser prompts to download cfm files instead of running them

New Here ,
Feb 05, 2020

Copy link to clipboard

Copied

Hi everyone,

     I have a new web server running Server 2016 and CF 2018 Standard.  No issues with install and the cfadmin site opens and runs fine.  However, the additional sites we have added will not run cfm or any of the other associated file types.  All it does is prompt for a download.  I've checked everything I can think of and still no luck.  Below is the list of what I have tried.  I'm hoping someone out there has a silver bullet for this issue.  Appreciate any help you can provide.  Thanks!

 

  • Have removed and added the web servers in the Adobe Web Server Configuration tool
  • Have removed and added the app pools associated with the web sites
  • Have checked all file permissions to make sure both the CF user and the App Pool have access
  • Have checked all CF settings with a different server (same config) that is working as expected
  • Have checked all IIS settings with a different server as well
TOPICS
Server administration

Views

601

Likes

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
Feb 05, 2020 0
Adobe Community Professional ,
Feb 05, 2020

Copy link to clipboard

Copied

Pick one sample site, and in the IIS UI for that site check the following :

  • Isapifilters for tomcat
  • Handler mappings for cfm extension
  • Jakarta virtual directory 

Do all those (for that one site) point to the same numbered folder, in the cf2018 config/wsconfig folder?

 

If so, are there any other handler mappings for cfm that point anywhere else? Are there any mappings that have a name starting with abo?

 

Finally, are there any mime types (for that sample site) for "air"?

 

If none of those are true and no one thinks of anything else, and you need this solved, I am confident we could find and fix the issue in 15 mins or less in a shared desktop session  (paid consulting), where perhaps I'd see something you have missed. If not, you'd not need to pay for the time. More at carehart.org/consulting. I realize that may not be an option for you, but sometimes there's just no substitute for eyes on the problem directly. 

/Charlie (server troubleshooter, carehart.org)

Likes

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
Reply
Loading...
Feb 05, 2020 0
New Here ,
Feb 05, 2020

Copy link to clipboard

Copied

Thanks Charlie.  I have verified that everything is in place.  The MIME type of .air was a new one to me.  It is there.  Should it be?  I'm not ready to engage for consulting yet, but I may get there and will let you know.  Thanks again.

Likes

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
Reply
Loading...
Feb 05, 2020 0
Adobe Community Professional ,
Feb 05, 2020

Copy link to clipboard

Copied

It's an old MIME type and can interfere with other things going on, so I'd recommend you get rid of it.

 

Dave Watts, Eidolon LLC

Likes

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
Reply
Loading...
Feb 05, 2020 0
Adobe Community Professional ,
Feb 05, 2020

Copy link to clipboard

Copied

Sorry, yes. I should have added, "and if you ind the air handler mapping, remove it".

 

Try it and see if it alone may well help.

/Charlie (server troubleshooter, carehart.org)

Likes

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
Reply
Loading...
Feb 05, 2020 0
Adobe Community Professional ,
Feb 05, 2020

Copy link to clipboard

Copied

This indicates a problem with the web server connector configuration. CF doesn't rely on IIS application pools, so you can safely disregard them as long as they're not set to 32-bit on a 64-bit CF/IIS install (that's a long shot). Like Charlie said, there are several places where IIS configuration is done by the connector: handler mappings, ISAPI filters within the site's configuration options, and a /jakarta virtual directory within the site itself. You should also be able to see configuration information within the wsconfig folder for the specific wsconfig installation that points to the site.

 

If possible, remove ALL sites from the CF web server configuration tool. Make sure you run the tool as an administrator.

 

Dave Watts, Eidolon LLC

Likes

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
Reply
Loading...
Feb 05, 2020 0
New Here ,
Feb 05, 2020

Copy link to clipboard

Copied

Thanks Dave.  I did remove ALL sites and added them back in under admin credentials just to make sure.  Same results.  Appreciate you taking the time to check out the post.

Likes

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
Reply
Loading...
Feb 05, 2020 0
New Here ,
Feb 07, 2020

Copy link to clipboard

Copied

Hi everyone,

     I finally found the problem.  The ISAPI-dll handler mapping was not correct and IIS would not let me change it.  I had to go to the applicaiton.config file and change it there.  Since the change everything is working.  I appreciate everyone's willingness to help.  Thanks.

Likes

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
Reply
Loading...
Feb 07, 2020 0
Adobe Community Professional ,
Feb 07, 2020

Copy link to clipboard

Copied

Really glad to hear that you have resolved things, but for the sake of others who may find this later, can you clarify please what change you made? It's a pretty straightforward handler definition (and FWIW you can indeed "edit" the handler mapping details, at the site or server level), so it would be very interesting what needed to "change".

 

Or was it perhaps about the order of that handler-mapping relative to others? If so, where in the list of them did you move  it to? The default is indeed for it to be listed first. If someone had changed that order, then sure that could have been a problem--and of course a challenging one to have anticipated. There's little reason for one to change the order of those.

 

But note that IIS provide for you to do that, in the UI.  There's a "view ordered list" feature on the right, when viewing them, and once that list appears you can use the "move up/down" option.

 

Again, just sharing all that if it may help future readers, even if you may have done it by hand (and I assume you meant in the applicationhost.config file). But it would be helpful also for any who find this thread in the future, to know what exactly you did have to change. Thanks.

/Charlie (server troubleshooter, carehart.org)

Likes

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
Reply
Loading...
Feb 07, 2020 0
Community Beginner ,
Feb 11, 2020

Copy link to clipboard

Copied

I have a similar issue with this code. It used to work on version 9.2 and stopped working in 2016.

It used to download a PDF but now it downloads the .cfm

Anybody have any ideas?

<cfsetting enablecfoutputonly="Yes" showdebugoutput="No">

<cfset name = "#Trim(session.stUser_Info.First_Name)# #Trim(session.stUser_Info.Last_Name)#">
<cfset ExpDate = DateAdd('yyyy',2,session.stUser_Info.Certificate_Date)>
<cfset cert = DateFormat(session.stUser_Info.Certificate_Date, "mm/dd/yyyy")>
<cfset exp = DateFormat(variables.ExpDate, "mm/28/yyyy")>
<cfif session.stUser_Info.AEDCertificate_Date EQ 1>
<cfcontent type="application/vnd.fdf">

<cfoutput>%FDF-1.2

%’“¦²

1 0 obj

<<

/FDF << /Fields [

<< /V (#exp#) /T (RENEWDATE)>>

<< /V (#name#) /T (YOURNAME)>>

<< /V (#cert#) /T (CERTDATE)>>

]

/F (https://www.mydomain.com/user/CERTUSERAED.pdf)

>>

>>

endobj

trailer

<<

/Root 1 0 R

 

>>

%%EOF</cfoutput>

<cfelse>
<cfcontent type="application/vnd.fdf">

<cfoutput>%FDF-1.2

%’“¦²

1 0 obj

<<

/FDF << /Fields [

<< /V (#exp#) /T (RENEWDATE)>>

<< /V (#name#) /T (YOURNAME)>>

<< /V (#cert#) /T (CERTDATE)>>

]

/F (https://www.mydomain.com/user/Certuser.pdf)

>>

>>

endobj

trailer

<<

/Root 1 0 R

 

>>

%%EOF</cfoutput>
</cfif>

Likes

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
Reply
Loading...
Feb 11, 2020 0
New Here ,
Feb 11, 2020

Copy link to clipboard

Copied

Hi Charlie,

    What I found was that th ehandler mapping for ISAPI-dll was the wrong type for the sites that were prompting for the .cfm download.  It should be a Module Mapping, but it was showing as a Script Map and was requiring me to enter an Executable even though it was optional.  I could remove and readd as a Module Mapping and it would revert back.  The only way I found to make the change permanent was to go change the application.config file.  Does that help  clarify?  Thanks again.

Likes

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
Reply
Loading...
Feb 11, 2020 0