Hi

Having more issues with a JSON request. the page calling the service is case 
sensitive, this was solved using the bracket structure syntax: i.e. 
response['hotspots'] = []; to preserve the case of the key. however I have an 
array I have tried added the array different ways to the struct but it still 
comes out uppercase!

                        <cfscript>
                        var response  = StructNew();
                        var tempArray=ArrayNew(1);
                        var obj = "";
                        response['hotspots'] = [];
                        
                
                        obj = 
                        
                        {
                        
                        distance = "100",
                        attribution="This is a test layer POI provider",
                        title= "My layer - snowy4",
                        lon= "53.472696",
                        lat="-2.261843",  
                        imageURL="null",
                        line4="RADIOLIST-None,CustSlider-None", 
                        line3="SEARCHBOX - asdfdgxdg", 
                        line2="DevlId - 896Settings: range=1000'", 
                        actions="", 
                        type="0", 
                        id="test_1"
                        
                        };
                
                        
                        arrayappend(response['hotspots'],obj);
        
        
                        
                        response['layer'] = "testme";
                        response['errorString']='ok'; 
                        response['morePages']='false';
                        response['errorCode']= '0'; 
                        response['nextPageKey']='null';

                        </cfscript>

   also tried

                        <cfscript>
                        var response  = StructNew();


                        
                        
                        response['hotspots'] = [
                        
                        {
                        
                        distance ="100",
                        attribution="This is a test layer POI provider",
                        title= "My layer - snowy4",
                        lon= "53.472696",
                        lat="-2.261843",  
                        imageURL="null",
                        line4="RADIOLIST-None,CustSlider-None", 
                        line3="SEARCHBOX - asdfdgxdg", 
                        line2="DevlId - 896Settings: range=1000'", 
                        actions="", 
                        type="0", 
                        id="test_1"
                        
                        }];
                        arrayappend(response, hotspots);
        
        
                        
                        response['layer'] = "testme";
                        response['errorString']='ok'; 
                        response['morePages']='false';
                        response['errorCode']= '0'; 
                        response['nextPageKey']='null';

                        </cfscript>



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:335007
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to