coldfusion

Wrong HBM mappings when using a mapped superclass in an inheritance graph for ColdFusion 9.0.1 Hotfix 2

不羁的心 提交于 2019-12-12 17:28:11
问题 Let's say I have an inheritance graph where the base class extends a mapped superclass: component name="Entity" mappedSuperClass="true" { property name="CreatedOn"; } component name="Pet" extends="Entity" table="Pet" discriminatorcolumn="pet_type" { property name="PetId" fieldtype="id" generator="native"; property name="Name"; } component name="Dog" extends="Pet" table="Pet" discriminatorvalue="Dog" { property name="FavoriteFood"; } component name="Cat" extends="Pet" table="Pet"

JSON response from my CFC is retunring HTML code

走远了吗. 提交于 2019-12-12 17:20:40
问题 I have a strange issue here. I am making a call to a CFC using jquery and returning a string. I am then trying to populate a form field with that string. For some reason, my response is including HTML code along with the query results. Here is how the JSON response looks in the console: > Gary Turner check_out.cfm:146 Successfully ran JSON, now changing > input value check_out.cfm:149 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML > 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1

Coldfusion and jquery ajax

非 Y 不嫁゛ 提交于 2019-12-12 17:17:15
问题 My cfc is working because I can invoke it and get the json string of data, however, my jquery ajax call gives me an error "SyntaxError: JSON.parse: unexpected end of data". ajax call: $.ajax({ type: "get", url: "/surveymanagement/admin/client.cfc", dataType: "json", data: { method: "GetClientsByName", name: "im" }, success: function(data){ $("#here").html(data); }, error: function(a,b,c){ $("#here").html(a.responseText + c); } }); When I invoke the component in another cfm page my cfc returns

Workaround for CFIDE Not Web Accessible for AJAX and Flash Built-Ins

蓝咒 提交于 2019-12-12 17:15:43
问题 Several pieces of ColdFusion functionality - media player and multi file uploader - are predicated on JavaScript libraries being available at /CFIDE/scripts , even if the scriptsrc is configured in Application.cfc . See the bug here for a point of reference: http://www.elliottsprehn.com/cfbugs/bugs/83328 Unfortunately exposing the CFIDE directory as-is from a ColdFusion installation is a security risk. So I'm trying to decide the right path forward to enable my application's use of this

onSessionEnd has different rootpath then my running application

岁酱吖の 提交于 2019-12-12 17:08:14
问题 I've got a service in my applicationScope that returns an custom object. <cffunction name="getObject" access="public"returntype="com.my.Object"> this is works fine in my application but when i call this function from onSessionEnd like: arguments.ApplicationScope.service.getObject() I get an error that it cannot find the component or interface. When i use a expandPath("/") when calling it from the website i get the path c:/websites/project/htdocs when i call the same from the onSessionEnd i'll

Creating an Alphabetical Indexed List (ColdFusion + Microsoft SQL Server)

試著忘記壹切 提交于 2019-12-12 16:26:31
问题 I'm currently struggling to find anyone who knows how this can be done? I've tried a few different methods and ended up with halfway results but not quite what i wanted. Basically i'm trying to create a list showing all the bands A-Z, but the band names are being called from a database, so i'm having to use #band_name# within a nested list. If i re-write the code and post it, someone might be able to see where i'm going wrong. <cfoutput query="bandNameList"> <cfloop from="65" to="90" index="i

How to specify argument attributes in CFscript? (CF9)

非 Y 不嫁゛ 提交于 2019-12-12 16:16:47
问题 In CF9 doc: Defining components and functions in CFScript, it says: /** *Comment text, treated as a hint. *Set metadata, including, optionally, attributes, in the last entries *in the comment block, as follows: *@metadataName metadataValue ... */ access returnType function functionName(arg1Type arg1Name="defaultValue1" arg1Attribute="attributeValue...,arg2Type arg2Name="defaultValue2" arg2Attribute="attributeValue...,...) functionAttributeName="attributeValue" ... { body contents } How do you

Coldfusion - How to parse and segment out data from an email file

♀尐吖头ヾ 提交于 2019-12-12 13:41:11
问题 I am trying to parse email files that will be coming periodically for data that is contained within. We plan to setup cfmail to get the email within the box within CF Admin to run every minute. The data within the email consists of name, code name, address, description, etc. and will have consistent labels so we are thinking of performing a loop or find function for each field of data. Would that be a good start? Here is an example of email data: INCIDENT # 12345 LONG TERM SYS# C12345

Issue using .net web service from ColdFusion

独自空忆成欢 提交于 2019-12-12 13:28:06
问题 I've been running into some challenges with a web service I'm trying to use of from ColdFusion. The service (AccountsService), has a method, GetAccountLinksByUser that returns accounts associated with a given user. This method accepts two arguments: UPN, which is just a unique string to identify the user. This is no problem, as far as I can tell. sourceType. This is ultimately a string, but is defined in the WSDL as simple type with one of three possible values. Here's a relevant sections of

How do I enable gzip compression on a coldfusion at the directory level?

时光怂恿深爱的人放手 提交于 2019-12-12 13:22:02
问题 I'm supporting a legacy application on ColdFusion 7, and the pages are full of painful amounts of whitespace that I'd like to gzip away. I know I can: manually compress everything in an index type file (reference) enable it in the web.xml (which I don't have access to) But can I just throw the right < cfheader > or something akin to a .htaccess that triggers gzipping on this directory? 回答1: There are two ways to implement compression. At the web server level (apache 1.3 with mod_gzip or mod