coldfusion-9

cfc that bring in additional functions via include

流过昼夜 提交于 2020-01-05 21:05:12
问题 My application.cfc starts with: <cfcomponent extends="org.corfield.framework"> later on void function setupApplication() output="false" { I have // tools include "initapp.cfm"; initapp.cfm has nothing but functions in it. Things like: <!--- Helper functions ---> <cfscript> string function stripHTML(str) output="false" { return REReplaceNoCase(arguments.str,"<[^>]*>","","ALL"); } application.stripHTML = stripHTML; </cfscript> The nature of the functions is NOT associated with a session. Is

Converting MailGun cUrl to Coldfusion

偶尔善良 提交于 2020-01-05 08:56:49
问题 I'm attempting to perform actions on a Mailgun mailing list using Coldfusion. Mailgun have supplied the following cUrl: curl -s --user 'api:key-xxxMyAPIkeyxxx' -G \ https://api.mailgun.net/v3/lists/myList@myDomain.mailgun.org/members I can get a good response by simply entering https://api:key-xxxmyAPIkeyxxx@api.mailgun.net/v3/lists/myList@myDomain.mailgun.org/members But I've had no luck converting this into a CFHTTP call: <cfhttp url="https://api:key-xxxmyAPIkey@api.mailgun.net/v3/lists

Coldfusion using onRequestEnd() with Application.cfm files

最后都变了- 提交于 2020-01-04 06:04:32
问题 I'm working in a legacy app that was built upon the use of Application.cfm files rather than Application.cfc files. There is a need to be able to run code after a request has processed. (Basically, I am wanting to use the <cfhtmlhead> tag to inject some Javascript and CSS files into every loaded document. Before I was doing this with a GreaseMonkey user script, but something server-side would be best.) From what I read, I think I should be able to do this with the onRequestEnd() function,

Coldfusion StructDelete creates blank value

末鹿安然 提交于 2020-01-04 04:06:08
问题 I'm using Codlfusion 9's StructDelete() method to remove a value from a cookie. But after using StructDelete(cookie,"selector12") I'm getting a value of [empty string] for cookie.selector12 despite deleting it This is the code I'm using: <cfdump var="#cookie#"> <!--- kill any existing selector cookie when looking at a profile ---> <cfset structDelete(cookie,'selector#URL.clk#')> <cfdump var="selector#URL.clk#"> <cfdump var="#cookie#"> To give the following output: Does StructDelete actually

How do I determine if a scheduled task was ran automatically or ran in a browser?

旧巷老猫 提交于 2020-01-03 03:24:07
问题 I am running some code as a scheduled task, setup in CF Administrator. Is there a way to tell in the code that the code ran as a scheduled task, whether it was ran by clicking the run icon in the CF Administrator scheduled task area, or whether it was called directly in a browser? Adding additional variables will not work? 回答1: From the test link in the CF admin If you're asking if you can identify the difference between a scheduled task being run manually by clicking the test link in the

Dealing with MySQL NativeError Code 1366 and SQLState HY000 in coldfusion

陌路散爱 提交于 2019-12-31 06:13:34
问题 Please find the initial few lines of stack trace of the error below: (The column sl is what I have used in the stored procedure code) Incorrect string value: '\xC2\x80\xC2\x99t ...' for column 'sl' at row 1 at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:946):946 at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2985):2985 at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1631):1631 at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1723):1723 at com.mysql.jdbc

ColdFusion 9.01 on Java 7

核能气质少年 提交于 2019-12-30 11:54:07
问题 Is there a list of what is broken when trying to Run ColdFusion 9.01 on Java 7? I have experienced issues with PDF generation. This Link: http://blogs.coldfusion.com/post.cfm/java-7-support-for-coldfusion suggests that it is related to textarea on PDF But is there a complete list of known issues? 回答1: Java 1.7 Update 15 is now officially supported with Cumulative Hotfix 3 (now superseded by 4) http://helpx.adobe.com/coldfusion/kb/cumulative-hotfix-3-coldfusion-901.html 回答2: It's just like the

Exporting SSL Certificate in Linux Browser (or Linux Command Line) for Java Certificate Truststore

霸气de小男生 提交于 2019-12-25 00:36:06
问题 Background: I am having some trouble consuming a Web Service with ColdFusion 9 (peer not authenticated). First, I'm going to try importing the cert into ColdFusion's underlying Java keystore. If that doesn't work, I'm going to try to fiddle with ColdFusion's security provider. But my questions are more specific... Question: How do I export the cert (at the right level) in Chrome (or Linux CLI), and in which format? Details I have seen some instructions for exporting a cert from a browser, but

cfpdf merge error when trying to merge multiple pdf files

纵然是瞬间 提交于 2019-12-24 13:52:52
问题 I'm using CFPDF to merge multiple PDFs together. The PDFs were created using wkhtmltopdf 0.12.1. In most cases the code works fine, but 2 of my documents error whenever merged together. My online searches came up empty and I'm really at a loss. Any help is greatly appreciated. <cfpdf action="merge" destination="#outputFile#" overwrite="yes"> <cfloop index="i" from="1" to="#arrayLen(pdfFiles)#"> <cfpdfparam source="#pdfFiles[i]#"> </cfloop> </cfpdf> The error occurs on line 173 <cfpdfparam

Decimal numbers in a HTML cfgridcolumn

给你一囗甜甜゛ 提交于 2019-12-24 12:04:59
问题 For some reason all my cfgrids drop the ending 0 of dollar amounts. So 104.50 is coming up as 104.5 and 332.80 is coming up as 332.8 It displays the last digit if it is not a 0. So 345.43 is fine. I have tried using the currency type but that only works with flash grids. This seems like an easy problem but I am stuck and everything I am trying is not working. Any help on this would be great. Thanks! 回答1: This is for CF9 (ExtJS 3.x). <cfsavecontent variable="formatGridInit"> <script language=