PDA

View Full Version : interaction with back-end perl scripts?


subatomicsatan
04-18-2005, 01:06 PM
hello all,

i'm brand new here and am currently downloading laszlo.

what i would like to do is create a dynamic user interface that modifies itself based upon data returned by back-end perl scripts. so, there would be user interaction in choosing what to look at, what level of detail they want, and allowing them to submit data.

each of these actions would have to either send or receive data to/from a back-end perl script. these back-end scripts will retrieve data from either a relational database or flat files and the data will be used to alter the user interface.

my question is: how might one do this in laszlo?

forgive me if this detailed elsewhere--i did look around a bit, but did not find the answer i was looking for, so any help would be greatly appreciated.

thanx!
james

rolfpf
04-18-2005, 04:08 PM
James,
OK, you have a framework worked out. That is you have the skeleton of what you want--now you need to put some flesh around it.

Try this, you know that the datasets that get passed to Laszlo are XML, you also know that you can use your PERL script to retrieve relational data from a database.

So the question is how are you going to convert the RDBMS data to XML?

subatomicsatan
04-18-2005, 04:14 PM
thanx for the reply!

i plan to modify the perl scripts to output in XML.

how does one pass data to a perl script?

james

rolfpf
04-18-2005, 05:46 PM
You pass data the same way that you pass it in PHP, except that PERL is an older language so you need to use CGI.

So in PHP it would be:
"http://www.domain.com/services/xmlrpc.php"

In PEARL it would be (ahh!):
"http://www.domain.com/services/xmlrpc.cgi"

This is where you are going to have some performance problems, me thinks.

subatomicsatan
04-18-2005, 05:54 PM
ah, OK. makes perfect sense...

thanx again for your help!

james

hqm
04-19-2005, 08:05 AM
There's a PERL apache module which would be more efficient and better integrated I imagine. But
I would never voluntarily use Perl for this kind of application... PHP is more suited to web server apps.