Solved

Reading coldfusion in .html files

Posted on 2007-03-28
3
432 Views
Last Modified: 2013-12-24
I am on a Windows server with coldfusion mx 7 and apache.

I know this is possible by somehow tuning my server settings, but am very rusty since I haven't touched coldfusion in over a year.

I want to be able to read coldfusion language within .html files. Basically, being able to run coldfusion with a file saved as .html.

What exactly do I have to configure to be able to do that?
0
Comment
Question by:ShytKicker
3 Comments
 
LVL 1

Accepted Solution

by:
jduawa earned 500 total points
ID: 18815804
have a look @ http://www.activsoftware.com/apache/apache2cfmx.cfm
you may just need to edit this section to include .html
LoadModule jrun_module "/opt/coldfusionmx/runtime/lib/wsconfig/1/mod_jrun20.so"
 <IfModule mod_jrun20.c>
    JRunConfig Verbose false
    JRunConfig Apialloc false
    JRunConfig Ssl false
    JRunConfig Ignoresuffixmap false
    JRunConfig Serverstore "/opt/coldfusionmx/runtime/lib/wsconfig/1/jrunserver.store"
    JRunConfig Bootstrap 127.0.0.1:51010
    #JRunConfig Errorurl optionally redirect to this URL on errors
    AddHandler jrun-handler .cfm .cfc .cfml .jsp .jws
 </IfModule>
0
 
LVL 8

Expert Comment

by:pmascari
ID: 18819531
Are you wanting to execute CF code in the HTML page?

You could read the HTML file, write it to a temp CFM file and then run it.

<cffile action="read" file="#absolute_server_path#/#your_HTML_file#" variable="TempRead">
<cflock timeout="500">
<cffile action="WRITE" file="#absolute_server_path#/temp.cfm" output="#TempRead#">
</cflock>
<cflocation url="temp.cfm">
0
 
LVL 7

Author Comment

by:ShytKicker
ID: 18840878
You are a genious my friend! Works perfectly, thanks!
0

Featured Post

Resolve Critical IT Incidents Fast

If your data, services or processes become compromised, your organization can suffer damage in just minutes and how fast you communicate during a major IT incident is everything. Learn how to immediately identify incidents & best practices to resolve them quickly and effectively.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hi, I will be creating today a basic tutorial on how we can create a Mail Custom Function and use it where ever we want. The main advantage about creating a custom function is that we can accommodate a range of arguments to pass to the Function and …
This is an updated version of a post made on my blog over 3 years ago. It is unfortunately, still very relevant as we continue to see both SQLi (SQL injection) and XSS (cross site scripting) attacks hitting some of the most recognizable website and …
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question