Quantcast
Channel: Adobe Community : Unanswered Discussions - ColdFusion
Viewing all articles
Browse latest Browse all 5794

I am having trouble with an XML feed Can You Help?

$
0
0

Any help would be appreciated

 

I have created a cf file as follows:

<cfxml variable="properties">

<cfquery name="GetPropertiesForFeed">Select PropertyReference, Price, Urbanisation, Location, PropertyType, FloorArea, Bedrooms, Bathrooms, Image1, Image2, Image3,

Image4, Image5, Image6, Image7, Image8, Description, Descriptionsp From Properties</cfquery>

<properties>

<cfloop query="GetPropertiesForFeed">

<property>

  <reference>#PropertyReference#</reference>

         <price>#Price#</price>

         <urbanisation>#Urbanisation#</urbanisation>

         <location>#Location#</location>

         <type>#PropertyType#</type>

         <area>#FloorArea#</area>

         <beds>#Bedrooms#</beds>

         <baths>#Bathrooms#</baths>

         <images>

         <image><url>http://primrose-realestate.com/propimages/#image1#</url></image>

         <image><url>http://primrose-realestate.com/propimages/#image2#</url></image>

         <image><url>http://primrose-realestate.com/propimages/#image3#</url></image>

         <image><url>http://primrose-realestate.com/propimages/#image4#</url></image>

         <image><url>http://primrose-realestate.com/propimages/#image5#</url></image>

         <image><url>http://primrose-realestate.com/propimages/#image6#</url></image>

         <image><url>http://primrose-realestate.com/propimages/#image7#</url></image>

         <image><url>http://primrose-realestate.com/propimages/#image8#</url></image>

         </images>

         <descriptions>

         <en>#Description#</en>

         <nl>#Descriptionsp#</nl>

  </descriptions>

</property>

</cfloop>

</properties>

</cfxml>

<!---<cfdump var=#properties#>--->

<cfset XMLText=ToString(properties)>

<cffile action="write" file="XMLfeed.xml" output="#XMLText#">

 

The xml file produced looks like this:

 

<properties>

 

<property>

 

 

<reference>#PropertyReference#</reference>

 

<price>#Price#</price>

<urbanisation>#Urbanisation#</urbanisation>

<location>#Location#</location>

<type>#PropertyType#</type>

<area>#FloorArea#</area>

<beds>#Bedrooms#</beds>

<baths>#Bathrooms#</baths>

 

<images>

 

 

 

 

 

 

 

 

 

</images>

 

<descriptions>

 

 

<en>#Description#</en>

 

<nl>#Descriptionsp#</nl>

</descriptions>

</property>

</properties>


The fields are not picking up the data.


Any suggestions please.


Viewing all articles
Browse latest Browse all 5794

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>