coldfusion

Why can't my coldfusion cfc access a udf included in application.cfm?

I've got a logging function (can't use cflog) included in application.cfm and my .cfm pages can access this, but any components I use give me a "Variable LOGGER is undefined." error. application.cfm <cfinclude template="logging.cfm"> logging.cfm <cffunction name="logger" > ... </cffunction> Any ideas as to what I'm doing wrong? ...

ColdFusion DataSource not found

I'm trying to connect ColdFusion 8 to SQL Server 2008 Express and I'm experiencing some issues when I try and run CF queries. When I try and run a query I get: (data source name removed, I didn't use [Name]) Datasource [Name] could not be found. The error occurred in [FilePath]: line 1 1 : <cfquery name="tasks" datasource="[Name]" > ...

How do I sort a query object in ColdFusion 7?

I have a query object, with, say, fifteen rows returned. For all intents and purposes, I can't modify the SQL which generates the query object, but I need to sort this query object by column. Is there a way to do this in ColdFusion 7 without resorting to an external library? Edit: I should add: I've run a query on this query object, and...

how to set a server wide variable in coldfusion

as it stands i have to maintain a variable in my application.(cfm|cfc) to set the environment, which the application currently runs under. the environment being (development|test|production). i'd like to set and environment variable on the server itself, so that i can read its value in the application.cfm. is that possible? ...

Best tool for monitoring Coldfusion interoperability with .Net web service

Is there a tool to see the message sent to webservice hosted on an IIS server? I have a webservice written in .Net and our ColdFusion people are having trouble building a "complex" parameter. This problem is described from a ColdFusion perspective at: adobe forum question It runs when called from a .net client. While hosted on a server...

How to get around SerializeJSON in CF8 encoding non printable characters?

SerializeJSON creates JSON with non printable characters (i.e. ASCII 21) This is invalid JSON. How can I get round this. Would a regex removing the non printable characters work? What regex would remove non printable characters? ...

Problem with IIS with Multi ColdFusion Server Configuration

This is a multi ColdFusion configured server with cf7 and cf8 and the jrun located in the main C:\ . After editing the JVM.config and increasing the memory size to Xms1024m Xmx1024m and GC to XX:MaxPermSize=256m, and then restarting. I am unable to get any of my sites to load in the browser. One gives me a 404 and the other gives ...

Protobuf-net How to consume a WCF service in NET CF client?

Hello, I'm trying to consume a WCF webservice using the RPC capabilities of the Protobuf-net. Here's my service contract: namespace WcfEchoService { // NOTE: If you change the interface name "IService1" here, you must also update the reference to "IService1" in Web.config. [ServiceContract] public interface IEchoService ...

Common programming mistakes for ColdFusion programmer to avoid?

In the spirit of my other questions regarding "common programming mistakes ... to avoid" What are some common programming mistakes for a ColdFusion programmer to avoid? ...

nested pound signs around variable with nested loop variable

I have a table in a form with a loop around it that sets an index on all the name fields (form variables) that changes based on user input (user dictates how many tables get built). Once submitted, I take these variables and create a struct out of it. I know that a query object is already a struct, but I have to have each tables names un...

What is the status of ColdFusion today?

This may seem like flamebait, but I can assure you it is not intended to be. Having spent the last 10 years in the web business, I had heard of ColdFusion, but hadn't personally witnessed anyone using it, especially in recent years. My impression was that its heyday had passed. Recently I started doing business with a company that was...

Passing an ArrayCollection from ColdFusion to Flex (with BlazeDS)

When pushing objects from ColdFusion to Flex via BlazeDS, and mapping the classes using RemoteClass... [RemoteClass(alias="blah.blah")] ...is it possible to have ColdFusion "Arrays" (or some Java equivalent) automatically mapped to ActionScript ArrayCollections? This chap nearly had it, but not quite: http://www.richinternet.de/blo...

Can session be transfered to different domain pointing to the same CF instance?

Let's say I have localhost and localhost2 both pointing to 127.0.0.1 in //localhost/test/test.cfm (\wwwroot\test\test.cfm) <cfset session.name="HAHA"> <cfcookie domain=".localhost2" name="CFID" value="#session.cfid#"> <cfcookie domain=".localhost2" name="CFTOKEN" value="#session.cftoken#"> <cflocation url="//localhost2/test/test2.cfm" ...

Best way to return a string from an HTTPHandler to a page that POSTs this .ashx file

I have an ASP.Net HTTPHandler that gets POSTed from a ColdFusion web page whose FORM looks something like: <form name="sendToHandler" action="http://johnxp/FileServiceDemo2005/UploadHandler.ashx" method="post"> <input type="hidden" name="b64fileName" value="fileservice.asmx.xml" /> <input type="hidden" name="strDocument" value="Document...

Ajax requests, through MVC Framework (e.g. ColdBox) or not?

Do you fire ajax requests through the MVC framework of choice, or directly to the CFC? I'm leaning towards bypassing the MVC, since I need no 'View' from the ajax request. What are the pro's of routing ajax calls through MVC framework, like Coldbox? update: found this page http://ortus.svnrepository.com/coldbox/trac.cgi/wiki/cbAjaxHin...

Is the CFDUMP tag modifiable?

With ColdFusion MX7 if we encounter an exception we send an email to the development team containing dumps of the various data scopes including the form structure. This works great for debugging except in the case of an error when the user logs in. We end up getting the password printed out. So, the question is, is there a way to modi...

Testing for existance of FORM scope / struct in ColdFusion

Problem: When requesting the WSDL for a CFC, I get the following error: Variable FORM is undefined. It happens in this line of code, in the OnRequestStart method in application.cfc <cfif structKeyExists(form,'resetappvars')> <cfset OnApplicationStart() /> </cfif> If I request a specific method, it works fine. I have considered using...

Complicated Javascript Calculation

I've got a fairly large table that needs to have a total on the right side and bottom for daily totals. I've been able to get the side to total correctly, but not the bottom. I may be thinking too little of this, but currently I have this: (Yes, I know it's not correct and doesn't work. I was testing) script: HorizVertiCalc = functi...

CFML Design Pattern resources?

As with all development, CFML via ColdFusion, Railo or OpenBD we run into common programming problems. For these problems must programmer turn to patterns (or anti-patterns). However the classic resources like GOF and the modern Head First books both tend to focus on Java. While java is beautiful in its own right, all three cfml eng...

Horizontal and Vertical complicated Javascript Calculation and Coldfusion

Now the table is being populated with 2 loops and an array. I have to control everything through the classes I put on the input. Been working on this for a while, some insight would be helpful. Here is the loop and the inputs: <cfloop from="1" to="#ArrayLen(labels)#" index="r"> <tr> <td class="labels"><cfif ArrayIsDefined(...