XxBOSSMASTERxX
New Member
I need to dump an xml string (coming into a web service as a POST param), directly into a Mysql DB. The column into which I am writing is currently of type 'text', though I have tried blob as well.Right now, when I save the string and retrieve it later on using sql, it comes back in a serialized like format, like this:\[code\]a:1:{s:14:"<?xml_encoding";s:1502:"UTF-8?><record> <nodes></nodes> </record>";}\[/code\]Whereas, I need to parse that xml as a simplexml object, and hence need it to be better formed.This is what I am doing codewise:
- Accept Post Param in web service
- Serialize and store it in DB using doctrine ORM, kind of like$record->xml_rec = serialize($_POST)
- Retrieve it and echo it.