coldfusion

used structdelete and now Elementemployee.id is undefined in SESSION.

using coldfuion 9 I used structdelete(session,"Elementemployee.id") in one of my .cfm display files.Also in my application.cfc it defined as is <cfset tArray[1][2] = "#session.employee_id#"> and the error is `Elementemployee.id is undefined in SESSION.` Is there a way that i can reset it without following the method shown below...

cfchart ignores my scalefrom value

Hi all, I have the following codes in my page. The style variable holds the custom style. <cfchart chartheight="450" chartwidth="550" gridlines="9" yaxistitle="Score" scalefrom="20" scaleto="100" style="#style#" format="png" > <cfchartseries query="variables.chart_query" type="scatter" seriescolor="##000000" itemcolu...

How do I change ColdFusion Help to show ColdFusion 8 Documentation, instead of ColdFusion 9 Documentation?

I love ColdFusion Builder. But I don't like that the help only has CF9 Documentation. Is there any way to change this to have ColdFusion 8 Documenation? ...

Can we pass a whole Structure over an URL ?

Hi, I am opening a new popup window on click of an URL in my page. My question over here is Can i pass whole structure to the new page ? If thats not possible is there any simple method to do that ? ...

error : java.lang.String cannot be cast to coldfusion.cfc.CFCBeanProxy anyone know about this ?

Does anyone know about this error I get when I try to insert a foreign key value in my entry entity using ColdFusion 9 Hibernate integration? java.lang.ClassCastException: java.lang.String cannot be cast to coldfusion.cfc.CFCBeanProxy Root cause :org.hibernate.HibernateException: java.lang.ClassCastException: java.lang.String ...

Coldbox Security Interceptor

Hi I am new to coldbox and working on a guestbook messaging forum. does anyone know how I can apply some rule in coldbox to show edit and delete for specified users of admin or user in the edit page. I am not sure how to specify this as I already have my rules here as shown in securityRules.xml: SecurityRules.XML ehSecurity\.dspLo...

Is it possible to rebind sql paramters using the result from a cfquery?

When I run the following code: <cfquery name="someQuery" result="queryResult" datasource="wetakepictures"> SELECT id FROM events WHERE category_id = <cfqueryparam value="1" cfsqltype="cf_sql_integer"> OR title like <cfqueryparam value="%test%" cfsqltype="cf_sql_varchar"> </cfquery> <cfoutput> #queryResult.sql# <br /> #A...

Redirect parent of a page from a cfwindow

Hi All, I have a page with cfwindow that require the user to be logged in to view the content on the page. The problem at the moment is if the user logs into the site, then does nothing and the session times out, I have no way that I can think of to redirect the parent of the window to the login screen when the user opens it. So far I ...

Download file in coldfusion and read its content

cfhttp with a get to download the files. Does anyone have an example of cfhttp working? Are there special settings that need to be set up on the server side to get this tag to work. When I try the following code: <CFHTTP METHOD = "get" URL="http://data.bls.gov/PDQ/servlet/SurveyOutputServlet?series_id=LNU04032231&amp;years_o...

ColdFusion CFC implementation of C# Partial Class?

Does ColdFusion offer a mechanism for splitting CFCs into multiple files? I am NOT talking about extension, I am talking about splitting the SAME CFC into multiple files; the same way C# allows for "partial" classes. The reason for this is because I am using T4 to generate a bunch of CFCs and I want to be able to tag functionality onto...

Converting Flash frame to JPEG

We are attempting to convert a flash frame into a JPEG without using the Flex SDK or other adobe tools. Right now, we have a flash file that passes binary data over to a .cfm page, which uses the following code to change the headers: <cfset var = GetHttpRequestData()> <cfcontent type="image/jpeg"> <cfheader name="Content-Disposition" v...

Writing cfquery inside cfoutput tag ?

I am writing the cfquery inside the cfoutput tag. It can be written outside the cfoutput tag. My question here is do we have any performance issues if we write the cfquery inside the cfoutput ? ...

Problem using unicode in URLs with cgi.PATH_INFO in ColdFusion

Hi there, My ColdFusion (MX7 on IIS 6) site has search functionality which appends the search term to the URL e.g. http://www.example.com/search.cfm/searchterm. The problem I'm running into is this is a multilingual site, so the search term may be in another language e.g. القاهرة leading to a search URL such as http://www.example.com/s...

Why can't I pass a form field of type file to a CFFUNCTION using structure syntax?

I'm trying to pass a form field of type "file" to a CFFUNCTION. The argument type is "any". Here is the syntax I am trying to use (pseudocode): <cfloop from="1" to="5" index="i"> <cfset fieldname = "attachment" & i /> <cfinvoke component="myComponent" method="attachFile"> <cfinvokeargument name="attachment" value="#FORM...

single sign on using coldfusion with IIS version 5 using NTLM

Hi can anybody direct me on this and how does this get setup. I basically have an application that I want users to be automatically logged into when logging in windows using there id and password so basically they get authenticated to using my coldfusion application ? Any pointers would be greatly appreciated. Thanks :) ...

How can I convert BASE64 encoded HTML to GIF using ColdFusion?

I am receiving a BASE64 encoded string from a WebService. The string represents an HTML page, and I can use built-in ColdFusion functions to convert and display it. However, I need a GIF representation of the HTML page, and I'm wondering if there's any way to do this using ColdFusion. NOTE: The website I'm working on is ColdFusion 8. U...

Regular Expression find a phrase not inside an HTML tag

Hi there, I'm struggling a bit with this regular expression and wondered if anyone was about to help me please? What I need to do is isolate the 1st phrase inside a string which is NOT inside an HTML tag. So the examples I have at the moment are: This is some test text about <acronym title="Incomplete Test Syndrome" class="CustomClass...

CFExecute not performing command

<cfset LOCAL.cmd = expandPath('..\library\gm.exe') /> <cfset LOCAL.args = "convert image1.jpg image2.jpg" /> <cfexecute variable="gm" errorVariable="error" name="#LOCAL.cmd#" timeout="10" arguments="#local.args#" /> <cfdump var="#gm#" /> This code always results in an empty string in gm. No matter how I execute gm with or witho...

Coldfusion: insert new line into string

I would like to insert a line break into the first space between words in a string variable. Here is my code so far: <cfset myPosition = find(" ", #myVar#)> <cfset lineBreak = Chr(13)&Chr(10)> <cfset myVar = insert(#lineBreak#, #myVar#, #myPosition#)> What am I doing wrong? ...

ColdFusion Timeout Error

I have a scheduled task that runs once a day that builds an XML file that I pass off to another group. Recently the amount of data has greatly increased and is now causing the task to time out (I think). I have tried to optimize my script as much as possible but with no luck. It times out long before an hour and I don't get any kind of C...