PDA

View Full Version : Laszlo with coldfusion.


marcovth
10-15-2004, 11:44 AM
Hello ...

I saw a couple of posts where people had some problems
connecting to coldfusion with laszlo.

I am working for a poor science lab so I never had
the money to upgrade from CF5 to CFMX.

CF5 has no webservices and very limited xml capabilites, but I wrote these two cfml pages that
will display a query as a xml page, which you can
use in laszlo.

<canvas height="200" width="800" bgcolor="#D4D0C8">

<dataset name="query" autorequest="true" type="http" src="http://localhost/test/xml4lzx.cfm"/>
<inputtext width="90" name="memberID"></inputtext>
<button> submit
<method event="onclick">
var d=canvas.datasets.query;
var p=new LzParam();
p.addValue("query","address",true);
p.addValue("memberID",memberID.getText(),true);
d.setQueryString(p);
d.doRequest();
</method>
</button>

<simplelayout axis="y"/>
<view name="list" datapath="query:/address/record">
<simplelayout axis="x"/>
<text datapath="@memberID"/>
<text datapath="@address"/>
<text datapath="@whatevermore"/>
</view>

</canvas>

I must say, adding data in laszlo seems to be a bit tough.
I like the cfquery, cfoutput (cfloop) combination
in coldfusion. I hope future lzx versions will have
something similar.

- Marco.