[Rails] Re: Rails magic for MySQL -> XML file -> MySQL and back
again
Stef Telford
stef at ummon.com
Thu Aug 10 16:03:24 GMT 2006
Hey Tony,
Well, if your wanting to read and write xml files from the file
system, your best bet is -definitely- libxml. Unlike certain other
products that I could mention, the documentation is really rather good,
and gives working examples of how to do this. Url is
http://libxml.rubyforge.org/doc/.
Perhaps I am missing something, and thats always possible, but,
unless your wanting to write an xml editor that fits -inside- the web
browser, you have two ways that I see; xml-rpc (think WebDav sort of ;)
or libxml and command line.
Regards
Stef
Tony Martin wrote:
> Steff, thanks for your suggestion. however, I am wanting to save and reload
> xml files directly from the file system, so will be doing fileio not talking
> to another app. My aim is to provide an xml format that can be accessed
> directly from PCs on the network and edited without going through the web
> server.
>
> I am however making some progress. this is my first development in both
> rails and Ruby so I am feeling my way here.. I am building a
> replacement/conversion of an existing MS Access database, and trying to
> emulate fairly closely the original database functionality an view and I am
> pleased to say that Rails is generally excelling iteslf.
>
> On the XML side, I notice from Bill's earlier posts that there is an issue
> if I use builder to create and render an rxml view because after the
> render, i will not be able to redirect to a new page. What I am proposing
> to do is use Builder to directly create an XML string within the controller,
> save it to a file and then redirect to a page that will display the xml from
> the file and allow for some editing. If that sounds bizarre please let me
> know.
>
> If anyone has any pointers to xml file i/o and parsing I would be grateful.
>
> Thanks
> Tony
>
More information about the Rails
mailing list