Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x

ColdFusion Language

10K

Solutions

3K

Contributors

ColdFusion is a server-side rapid application development platform originally created by Allaire and now sold by Adobe, implementing the dynamic general purpose CFML programming language. The term ColdFusion is sometimes colloquially used to refer to the CFML language (Cold Fusion Markup Language), but can also include discussions of the server software implementation. ColdFusion runs using a customised version of Apache Tomcat. Earlier versions are bundled with JRun.

Share tech news, updates, or what's on your mind.

Sign up to Post

I am looking for idea. I need to grab locations , some of the lcoations have the same name but different locationID.

I need to create a location drop down with a unique locations. And then do the search by these locations. The question  is if I do make a drop down of unique locations thne in my search I will be searching by name instead of locationID
0
Enroll in September's Course of the Month
LVL 10
Enroll in September's Course of the Month

This month’s featured course covers 16 hours of training in installation, management, and deployment of VMware vSphere virtualization environments. It's free for Premium Members, Team Accounts, and Qualified Experts!

Hello,

I am having trouble reading an XML response.  I am not sure if I can explain it well.  I am using XMLParse on the filecontent.

When I do this directly from the response from the web service I am using, it seems that I am getting just one chunk of XMLText instead of each piece of information with its node label.

<cfdump var="#xmlparse(httpResponse.filecontent)#">

If I show the filecontent on the screen, then copy and paste it into notepad and name it something.xml, then run XML Parse, I am able to access the different nodes.

<cfdump var="#xmlparse("test.xml")#">

Below is the filecontent that I am able to create an xml document with and read successfully.

Attached are images of the two cfdump calls.  I think the pictures should explain it.

I am not sure if this has to do with XMLParse or with the response data that is being returned to me.

Any help would be much appreciated.  I have been trying to figure this out for two days now and am exhausted...



<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><ExecuteXMLResponse xmlns="http://rossinc.com/webservices/"><ExecuteXMLResult><method name="RS_BIN_TRANSFER"><database>_CONNECTSERVICE</database> <parameters><parameter> <name>ERROR_OCCURRED</name> <value>1</value> </parameter> <parameter> <name>XML_TAGS</name> <value>1</value> …
0
Hello Experts-

I have a list of names that I am calling a db query to pull the IDs, but am having trouble getting the IDs into an actual list.  It is returning 16 487 488 rather than 16,487,488

<cfset affiliateList = #form.id#><!--- Looks like.... C - DME Media,KC - Floor Coverings International - Google HL,KC - Floor Coverings International - Yahoo --->
    
     <cfloop list="#affiliateList#" index="i" delimiters=",">
        <cfquery name="getAffiliateID" dbtype="query">
            select affiliateID
            from getCampaigns
            where name IN ('#i#')
         </cfquery>
         
     	<cfoutput query="getAffiliateID">
        	<cfset finalList = valuelist(getAffiliateID.affiliateID,",")>
           <cfdump var="#finalList#"> 
         </cfoutput>
     </cfloop> 

Open in new window

0
Java Heap Space error being caused by a couple of different report queries in Cold Fusion using SQL script. I'm looking into issues that are causing this. This is early stage research as I'm not familiar w/ Java or this error. Any help is appreciated. From what I've seen its saying the code needs to be written in a more precise manner vs. merely increasing the memory allotment. A sample of the Cold Fusion/SQL query is below. Any suggestions as to where to start? There a total of 6 separate queries w/in the one file. The one provided is the first and "longest".

Thanks in advance.

<CFQUERY name="FPDWins" datasource="#dsn#">
select DocumentID,
    DocumentNum,
    RHRecordID,
	0 WorkitemInstanceID,
    LUFSBatchNum,
    ImageType,
    TransCode,
    LFPSStatus,
    to_char(DateToWINS,'MM/DD/YYYY') DateToWINS,
    to_char(WINSBatchID) winsbatchid,
    WINSRetrievalDate,
    WINSStatus,
    WINSContractNumber,
	to_number(p1.property_value) MarkviewDocID
  from qbd_lufs_wins_documents_v l,
       sf_workitem_property_values_v p1, 
       sf_workitem_property_values_v p2
 WHERE p1.property_name = 'MarkViewDocumentID'
   AND p1.workitem_instance_id = p2.workitem_instance_id
   AND p2.property_name = 'RHRecordID'
   AND p2.property_value = to_char(l.rhrecordid)
   and DocumentType = substr(upper('#DocID#'),1,2)
   and DocumentFiscalYear = substr(upper('#DocID#'),3,2)
   and DocumentNum = substr(upper('#DocID#'),5)
UNION
select cond.dafis_document_id DocumentID,
    

Open in new window

0
Trying to show member attendance at meetings. The concept here is that we would enter a meeting date, select the various members who attended, then be able to show a listing of which meetings a particular person attended, with the names in the first table column and meeting dates in successive columns. This is the code I am currently using but it gives a lot of false showings for each person

 <cfquery name="getDates" datasource="#conn#">
   select * from meeting_attendance
</cfquery>
<cfquery name="getMembers" datasource="#conn#">
   select * from members where member_userid <> 1
   and member_userid IN
         (select member_userid from meeting_attendance where attended = 1)
   order by lastname, firstname
</cfquery>
<cfoutput>
<table>
  <tr>
    <td>&nbsp;</td>
      <cfloop query="getDates" group='meeting_date'>
      <td>#dateformat(getDates.meeting_date, 'mm/dd/yyyy')#</td>
      </cfloop>
  </tr>
  <cfloop query="getMembers">
  <tr>
    <td>#getMembers.firstname# #getMembers.lastname#</td>
      <cfloop query="getDates">
      <td align='center'><cfif attended eq 1>Yes</cfif></td>
      </cfloop>
  </tr>
  </cfloop>
</table>
</cfoutput>

Example of current output

                            09/05/2017
member name      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Yes      Y
0
The following script is producing invoices.  It was working fine in 4.5, but my server has upgraded to CF 7.0.  The first invoice is produced, and then I encounter the error,  I have removed all addresses from the database except for the 20 or so valid ones from people who bid in the auction.  I am not a CF expert, and I am freaking out a little bit.

Here is the code:

<html>

<head>
<title>SEND INVOICES</title>
</head>

<body BGCOLOR="#FFFFFF">

<CFIF ParameterExists(ID) IS "NO"><CFSET ID=0></CFIF>
<CFIF ParameterExists(PASS) IS "NO"><CFSET PASS=0></CFIF>
<CFQUERY name="validate" DATASOURCE="DJS">SELECT * FROM ADMIN WHERE ID='#ID#' AND PASS='#PASS#'</CFQUERY>
<CFIF VALIDATE.RECORDCOUNT is 0><CFLOCATION URL="ERROR.CFM?ERROR=2"></CFIF>

<CFQUERY name="checkclose" datasource="DJS">select * from times where type='auction'</cfquery>
<CFIF #checkclose.enddate# LT #CreateODBCDateTIME(now())#>
<CFQUERY NAME="AUCTIONINFO" DATASOURCE="DJS" MAXROWS="1">SELECT * FROM TIMES</CFQUERY>

<CFQUERY NAME="lots" DATASOURCE="DJS">SELECT * FROM lots ORDER BY lot ASC</CFQUERY>

<CFLOOP QUERY="lots">

<CFQUERY name="highbidder" datasource="DJS" maxrows="1">SELECT * FROM bids WHERE lot = #lot# ORDER BY bid DESC</CFQUERY>

<CFIF HIGHBIDDER.RECORDCOUNT IS NOT 0>

<CFQUERY NAME="HBI" DATASOURCE="DJS" MAXROWS="1">SELECT * FROM MEMBERS WHERE MEMBERID='#HIGHBIDDER.MEMBERID#'</CFQUERY>

<CFQUERY NAME="CHECKTABLE" DATASOURCE="DJS" MAXROWS="1">SELECT * FROM WINTABLE WHERE …
0
Hi,
I currently use a cfdiv to bind to a data file (data.cfm).
This data.cfm file simply creates a CFquery and a html Table..

When I use ColdFusion.Navigate I can refresh the above div (called div1) easily.

However I have changed m CfDiv into a std html div and I am trying to use the $ajax.load function to reload the div.

I believe my calling code is correct.

 $('#div1').load('data.cfm?id=100');

However it seems jquery just ignores the server side code in my data.cfm file.
If I makes a blank data.cfm with a few lines of html the do refresh ok.

But not my data.cfm with what I need.
cfquery and cfoutput & table.

Any help would be appreciated..
0
I'm looking for help with an excel file export from a Cold Fusion form...The html version is working fine but the excel is blank. Has anyone had any issues w/ this. The form is working for the html and pulling from the db. The excel version is just blank with the same parameters.

The only modification was to increase the max size of a field to 17 from 16 in the index.htm file to account for an increased reference number. Simple change but and the test db has been updated w/ the criteria to pull from but for some reason the excel file isn't populating. I know this is vague but I'm hoping someone can shed some light or at least point me somewhere I can find some assistance. Thanks.
0
I'm looking for help getting a jump start on implementing SAML 2.0.   I have read a lot of documentation but it all seems geared towards the user-end, not the developer end.   Here is our situation.

We provide a website to corporate clients, each corporation has many users.   These companies have their own websites and their users have their own logins.   Our clients want their users to login to their website and be able to pass through to our website without needing a login on our website.

-Our clients' websites would login the user  and then pass the user onto our site without needing to login
-Our site would accept the user as long as the client says they are valid, we are ok accepting them.  
-We would create a corresponding user record on our end for each user

What do we need to do on our end to implement SAML?  
Can we code something and/or do we need a third party?
We code in Coldfusion (CF 11)

While I do understand Single Sign-On and the parts of SAML needed.  I have yet to find steps to actually implement.  Any help with this would be greatly appreciated.
0
MySql 5.7 / Coldfusion 11

I have a real estate property search form with multiple fields for instance  City, Price, Acres, etc... and a Keyword input that needs to be able to further filter these results.   Example: I need to be able to find only properties listed in a certain city by a certain agent the agents name goes in the "keyword" input.

I have 3 tables in my database that I need to query and do a fulltext search on; "listings",  "fagents", "fcoagents"  
so I added fulltext index for each.

ALTER TABLE listings ADD FULLTEXT(Class,Type,SubType,City,PropertyName,Highlights,Remarks,Agent,CoAgent,AddressNumber,AddressStreet,Zipcode);

ALTER TABLE fagents ADD FULLTEXT(AgentFName,AgentLName,AgentEmail);

ALTER TABLE fcoagents ADD FULLTEXT(AgentFName,AgentLName,AgentEmail);


SELECT * FROM listings
LEFT JOIN fagents ON listings.Agent = fagents.Agent
LEFT JOIN fcoagents ON listings.CoAgent = fcoagents.CoAgent

WHERE (Status = "Active" OR Status = "Pending")

AND

<!---Search by City--->
<cfif StructKeyExists(form,"City") and listLen(trim(form.City), ",")>
 AND City IN
        (
             <cfqueryparam value="#form.City#"
                   cfsqltype="cf_sql_varchar"
                   list="true"
                   separator=",">
     )
</cfif>

<!---Search by keywords--->
<cfif StructKeyExists(form,"Keyword") and len(trim(form.Keyword))>
AND
0
TCP/IP Network Protocol Cheat Sheet
TCP/IP Network Protocol Cheat Sheet

TCP/IP is a set of network protocols which is best known for connecting the machines that make up the Internet. The truth is that TCP/IP is one of the oldest network protocols and its survival is mainly based on its simplicity and universality.

I have been uploading pdf and jpg file from our local server to a hosted server using FTP. However, for security reasons the hosted server stopped the FTP service two weeks ago. The hosted server told us to start using CFHTTP to replace FTP.

We were using CFFTP for:
<cfftp action = "open"
<cfftp action = "remove"
<cfftp action = "close"
<cfftp action = "LISTDIR"
      Etc…

Does anyone have a Coldfusion example on how to transfer file from a local server to hosted server ? I have never used CFHTTP before
0
I have a ColdFusion 11 component which is supposed to populate a cfselect using bind. However, the select is not populated with the values at all. It shows blank. These are 2 select form controls that I want to relate to each other. A select from one should populate the other with values based on the selection made.cfselectbind.txtcfselectbind.txt
0
I need a form field mask for a date field to read: MM/DD/YY in a cold fusion form.

I have other fields working but the date field won't take. Would the letters vs. numbers be issue. My current code is setup for the mask:

<cfset session.invoiceDataContr.Invoice_Date = "MM/DD/YY" >

Open in new window

 <font face="Arial" size="2" color="#990000"><label for="Invoice_Date">Invoice Date:&nbsp;</label>
                        <input  id="Invoice_Date"  name="Invoice_Date" size="15" maxlength="8" type="date"  tabindex="8"  value="<cfif structkeyexists(session.invoiceDataContr, "PASS")><cfoutput>#session.invoiceDataContr.Invoice_Date#</cfoutput><cfelse><cfoutput>#form.Contract_Number#</cfoutput></cfif>" required/>

Open in new window

0
I need to validate a date field with MM/DD/YY requirements using a regex within a cold fusion form.
0
I'm trying to integrate a coldfusion app with MS sharepoint. Both sites are within the intranet so it shouldn't be anything network related. I'm able to browse to the wsdl file from a browser but the cfsharepoint tag part gives following error:

Unable to read WSDL from URL: https://nri.pcd.com/books/authors/_vti_bin/Lists.asmx?wsdl.

***********************************************************************************
Here's my cf code snippet:
***********************************************************************************
<cfscript>
      login = {domain="https://nri.pcd.com",
      username="uname", password="pwd"};
</cfscript>

<cfoutput>
      
            <cfsharepoint action="getlistcollection"
                  wsdl="https://nri.pcd.com/books/authors/_vti_bin/Lists.asmx?wsdl"
                  login="#login#"      name="result">
</cfoutput>

<cfdump var="#result#">
0
Current code that's breaking is:

1:^(([\w\!#$%&'*+-/=?^_`{|}~;]+(?:\.[\w\-_]+)*@(?:[\w\-_]+\.)+[a-zA-Z]{2,7})[;]?)+$

Open in new window


error message:

"Error","ajp-bio-8012-exec-5","07/31/17","10:55:57",,"Invalid CFML construct found on line 214 at column 73.ColdFusion was looking at the following text:<p>\'</p><p>The CFML compiler was processing:<ul><li>An expression that began on line 214, column 69.<br>The expression might be missing an ending #, for example, #expr instead of #expr#.<li>The tag attribute pattern, on line 214, column 53.<li>A cfparam tag beginning on line 214, column 6.<li>A cfparam tag beginning on line 214, column 6.<li>A cfparam tag beginning on line 214, column 6.</ul> The specific sequence of files included or processed is: D:\inetpub\wwwroot\centralinv\central_inv_contr_verify.cfm, line: 214"

I'm guessing the # is throwing an issue and maybe the $ and ^ ... anyone have any ideas to get around the coding errors for those characters:
0
Hello Experts,

I have trouble getting a Connection Failure. Status code unavailable. response  after waiting for longtime.

Response when using coldfusion to submit
response
Response when copy pasting the URL in the borwser

 
{
  "success": true,
  "challenge_ts": "2017-07-28T17:28:02Z",
  "hostname": "wsq02230"
}

Open in new window


<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
<cfsetting requestTimeOut = "9000" />
<cfparam name="FORM.username" default="" type="string" >
<cfparam name="FORM.password" default="" type="string" >

<cfif structKeyExists(FORM,"submit")>
	
	<cfset recaptcha = FORM["g-recaptcha-response"] >
	<cfif len(recaptcha)>
		
		<cfset googleUrl = "https://www.google.com/recaptcha/api/siteverify">
		<cfset secret = "XXXXXXX">
		<cfset ipaddr = CGI.REMOTE_ADDR>
		<cfset request_url = googleUrl & "?secret=" & secret & "&response=" & recaptcha & "&remoteip=" & ipaddr >
		
		<cfoutput>
		#request_url# 
				<cfoutput>
				<!--- <cfhttp url="#request_url#" method="post" timeout="10" result="captcharesult">
					<cfhttpparam name=remoteip value="#ipaddr#" type="url">
				</cfhttp> --->
				<cfhttp url="https://www.google.com/recaptcha/api/siteverify" method="post" result="captchaResult">
				  <cfhttpparam type="formfield" name="secret" value="#secret#"> 
				  <cfhttpparam type="formfield" name="response" value="#recaptcha#"> 
				  <cfhttpparam type="formfield" name="remoteip" value="#CGI.REMOTE_ADDR#"> 
				</cfhttp>
				
		

Open in new window

0
I have a cold fusion form which requires me to add a try catch around the form fields. I keep getting an error message however when I try to add it. Code below thanks for any help you provide if you see something obvious I'm missing.
 <cftry> 	
   	<cfif NOT refind("^[DdFfGgHhNnVv][A-Za-z0-9]{1,21}$", form.Contract_Number) AND NOT refind("^70[Zz]0[a-zA-Z0-9]{2}\d{2}[a-zA-Z][a-zA-Z0-9]{8}$", form.Contract_Number)>
   	<cfcatch>
	   <cfset #session.invoiceDataContr.errorString# = "The Contract Number is required and can contain no more than 22 alphanumeric characters.,">
	</cfif>
    </cfcatch>
</cftry>

Open in new window


error log message:
"Error","ajp-bio-8012-exec-3","07/25/17","11:45:07",,"Context validation error for the cfcatch tag.The tag must be nested inside a CFTRY tag. The specific sequence of files included or processed is: D:\inetpub\wwwroot\centralinv\central_inv_contr_verify.cfm, line: 121 "
0
Form field validation for a date requirement to be: Current date on or after 10/01/2017 - cold fusion form

A new requirement for a form. I need to detect the date a form is being submitted to be the current date on or after 10/01/2017 in a cold fusion form.

The date won't be placed into the form field/s but I need to detect the date. This will be implemented on 10/01/2017 fyi. I'll need to set the code up to test say for today's date then once working set it up to detect 10/01/2017 for when it goes live.

Thanks for any help. I'll start researching the topic as I've never tried to work this type of code before. Current code for one of the fields is:

  <cfset errorMsg = ""> 
   	<cfif NOT refind("^[DdFfGgHhNnVv][A-Za-z0-9]{1,21}$", form.Contract_Number) AND NOT refind("^70[Zz]0[a-zA-Z0-9]{2}\d{2}[a-zA-Z][a-zA-Z0-9]{8}$", form.Contract_Number)>
	   <cfset errorMsg = "The Contract Number is required and can contain no more than 22 alphanumeric characters.,">
	</cfif>
	<cfset session.invoiceDataContr.errorString = errorMsg>

Open in new window

0
Not sure which OpenStack Certification to get?
Not sure which OpenStack Certification to get?

So you’ve realized you might want to get certified in OpenStack, but you’re not sure what the benefits might be or even which one you should take. You know there are several certification courses you can choose from, but how do you know which one is right for you?

I need to validate 2 form fields w/ similar criteria for each field but each needs to validate w/ an older set of criteria and a new one. Code below:

  <cfset errorMsg = ""> 
   	<cfif NOT refind("^[DdFfGgHhNnVv][A-Za-z0-9]{1,21}$", form.Contract_Number) AND NOT refind("^70[Zz]0[a-zA-Z0-9]{2}\d{2}[a-zA-Z][a-zA-Z0-9]{8}$", form.Contract_Number)>
	   <cfset errorMsg = "The Contract Number is required and can contain no more than 22 alphanumeric characters.,">
	</cfif>
	<cfset session.invoiceDataContr.errorString = errorMsg>

Open in new window


     <cfset errorMsg = "">     
   	<cfif NOT refind("^[Hh][Ss][Cc][Gg][A-Za-z0-9]{1,21}$|^$", form.Task_Order) AND NOT refind("^70[Zz]0[A-Za-z0-9]$", form.Task_Order)>
	   <cfset errorMsg = "The Delivery/Task Order Number must begin with HSCG with a maximum of 25 alphanumeric characters. Do not use hyphens or special characters. The
Delivery/Task Order Number can be found in block 4 of the SF-1449 form or in block 3 of the OF-347 form.,">
	</cfif>	
	<cfset session.invoiceDataContr.errorString = errorMsg>

Open in new window


Do I need 2 different cfset params? Not sure what's up. won't catch the second validation
0
Hi, I have a dynamic CF page with  printout tables. Problem is with printing. Table printout can be split depending on the dynamic content. I need to force a new page for each table output. Is there a CF or html string I can use to force this break

many thanks
0
I have a very simple JSON feed and have been able to parse the feed using the below code. However, when the script gets to the "OFFERS" structure, it won't output the results cause it sees the brackets [ ] and is treating the data as a LIST of objects under OFFERS instead of objects like they would be under normal braces { }. I don't know how to get Coldfusion to properly give me the subitems of OFFERS.  You can easily see the feed using the link I provide also.

<cfoutput>
<cftry>
	<cfhttp url="https://rest.bandsintown.com/artists/spencerkane/events?app_id=day6mgmt&date=2017-08-19" result="httpResult" charset="utf-8" method="get"/>
 	<cfset BITdata = deserializeJSON(httpResult.filecontent)/>
	<cfloop array="#BITdata#" index="post">
		<cfif StructKeyExists(post, "datetime")>
			<cfset event_date = post.datetime>
		<cfelse>
			<cfset event_date = "">
		</cfif>
		<cfif StructKeyExists(post, "venue") and StructKeyExists(post.venue, "name")>
		    <cfset ev_title = post.venue.name>
		<cfelse>
            <cfset ev_title = "">
		</cfif>
		<cfif StructKeyExists(post, "venue") and StructKeyExists(post.venue, "city")>
			<cfset city = post.venue.city>
		<cfelse>
			<cfset city = "">
		</cfif>
		<cfif StructKeyExists(post, "venue") and StructKeyExists(post.venue, "region")>
			<cfset region = post.venue.region>
		<cfelse>
			<cfset region = "">
		</cfif>
		<cfif StructKeyExists(post, "offers[url]")>
		<cfset tickets = post.offers[url]>
			<cfelse>
		<cfset tickets = "">
		

Open in new window

0
Hi,

Am newbie to ColdFusion Please tell me code for login process am so confused for that can't get understand login process in my analysis.

Am tried below code,

My Form Code like,

  <!DOCTYPE html>
<html>
<head>
<title>Login</title>
Please Log In
</head>
<body>
    <cfform  name="LoginForm" action="" method="Post">
    <table>
    <tr>
    <td>Username:</td>
    <td><cfinput type="text" name="username" size="20" maxlength="30" required="yes" validate="maxlength,required" message="The Username must be between 1 and 30 characters."><br></td>
    </tr>
    <tr>
    <td>Password:</td>
    <td><cfinput type="password" name="password" required="yes" pattern="^[a-zA-Z0-9._]{8,16}$" maxlength="35" validate="required,regex" message="The Password must be between 8 and 16 characters."><br></td>
    </tr>
    </table>
    <br>
    <cfinput type="Submit" name="SubmitLoginForm" value="Submit">       
    </cfform>
      </body>
</html>

Am checking  username and password in below code,

<cfif isdefined("form.SubmitLoginForm")>
      <cfquery name="getpassword" datasource="testcf">
      select username, salt, password ,id from user where username = "#form.username#"
      </cfquery>      
      <cfif getpassword.RecordCount EQ 1>
      <cfset passwordHash = Hash(form.password & getpassword.salt, 'SHA-512') />
      <cfoutput>
      #getpassword.id#
      </cfoutput>
      <cfif getpassword.password EQ passwordHash>      
      
      <cfset session.allowin = "True">
      <cfset userid = '#getpassword.id#'/>
      <cfset…
0
Hello.

I would like to be able to browse C: \ wwwroot at http: // localhost: 8500 / test.
This is displayed as it is actually accessed.

” the page you are trying to access cannot be displayed.
please try again or notify the administrator ”

Using IIS, the physical path is set to C: \ wwwroot.
Check and set index.cfm in the default document

I'm using
windows server 2012 R2
IIS 8.5
ColdFusion 2016

I am a beginner. Please give me advice on which other setting to do.
0
<cfoutput>
<cftry>
	<cfhttp url="https://rest.bandsintown.com/artists/spencerkane/events?app_id=day6mgmt&start_date=2017-01-01" result="httpResult" charset="utf-8" method="get"/>
 	<cfset BITdata = deserializeJSON(httpResult.filecontent)/>
	<cfloop array="#BITdata#" index="post">
		<cfif StructKeyExists(post, "datetime")>
			<cfset event_date = post.datetime>
		<cfelse>
			<cfset event_date = "">
		</cfif>
		<cfif StructKeyExists(post, "venue.name")>
		    <cfset ev_title = post.venue.name>
		<cfelse>
            <cfset ev_title = "">
		</cfif>
		<cfif StructKeyExists(post, "venue.city")>
			<cfset city = post.venue.city>
		<cfelse>
			<cfset city = "">
		</cfif>
		<cfif StructKeyExists(post, "venue.region")>
			<cfset region = post.venue.region>
		<cfelse>
			<cfset region = "">
		</cfif>
		<cfif StructKeyExists(post, "offers.url")>
		<cfset tickets = post.offers.url>
			<cfelse>
		<cfset tickets = "">
			</cfif>

<!--- FEED OUTPUT --->        
<cfif not event_date is "">		
#event_date#<p>
#ev_title#<p>
#city#<p>
#region#<p>
#tickets#
<hr />
</cfif>		
	</cfloop>

	<cfcatch type="any">
		<p>
			<cfdump var="#cfcatch#" />
			#LSDateFormat(Now(), "dd-mm-yyyy")# #lsTimeFormat(Now(), "HH:mm")#<br />
			<a href="##">
				Oh, sorry... I can't connect to Bandsintown
			</a>
		</p>
	</cfcatch>

</cftry>
</cfoutput>

Open in new window


My output only gives me the datetime and none of the other structure data even though the raw feed in a browser window definitely shows there is more data to be displayed. I am using Adobe's output structure of data.struct1.substruct but it doesn't display anything.
0

ColdFusion Language

10K

Solutions

3K

Contributors

ColdFusion is a server-side rapid application development platform originally created by Allaire and now sold by Adobe, implementing the dynamic general purpose CFML programming language. The term ColdFusion is sometimes colloquially used to refer to the CFML language (Cold Fusion Markup Language), but can also include discussions of the server software implementation. ColdFusion runs using a customised version of Apache Tomcat. Earlier versions are bundled with JRun.

Top Experts In
ColdFusion Language