Re: Convert raw data to XML

2007-01-30 Thread Gabriel Genellina
[EMAIL PROTECTED] wrote: > is there any other way to do this without using BeautifulStoneSoup.. > using existing minidom or ext.. > i dont want to install anything new It appears that you already know the answer... Look at the minidom documentation, toprettyxml method. -- Gabriel Genellina -

Re: Convert raw data to XML

2007-01-30 Thread hg
[EMAIL PROTECTED] wrote: > On Jan 30, 12:05 pm, John Nagle <[EMAIL PROTECTED]> wrote: >> [EMAIL PROTECTED] wrote: >> > On Jan 29, 8:54 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: >> >> >>En Mon, 29 Jan 2007 23:42:07 -0300, <[EMAIL PROTECTED]> escribió: >> > the reason I wanted to write it a

Re: Convert raw data to XML

2007-01-30 Thread elrondrules
On Jan 30, 12:05 pm, John Nagle <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > On Jan 29, 8:54 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > > >>En Mon, 29 Jan 2007 23:42:07 -0300, <[EMAIL PROTECTED]> escribió: > > the reason I wanted to write it as a file was to parse the file, l

Re: Convert raw data to XML

2007-01-30 Thread John Nagle
[EMAIL PROTECTED] wrote: > On Jan 29, 8:54 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > >>En Mon, 29 Jan 2007 23:42:07 -0300, <[EMAIL PROTECTED]> escribió: > the reason I wanted to write it as a file was to parse the file, look > for a specific attribute and execute a set of commands bas

Re: Convert raw data to XML

2007-01-30 Thread elrondrules
On Jan 29, 8:54 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Mon, 29 Jan 2007 23:42:07 -0300, <[EMAIL PROTECTED]> escribió: > > > For example the raw data is as follows > > > SomeText > Description>PassorFail > > > without spaces or new lines. I need this to be written into an XML > > f

Re: Convert raw data to XML

2007-01-30 Thread John Nagle
Actually, that's not "raw data" coming in, that's valid XML. Why do you need to indent it? Just write it to a file. If you really need to indent XML, get BeautifulSoup, read the XML in with BeautifulStoneSoup, and write it back out with "prettify()". But if the next thing to see that XML

Re: Convert raw data to XML

2007-01-29 Thread Gabriel Genellina
En Mon, 29 Jan 2007 23:42:07 -0300, <[EMAIL PROTECTED]> escribió: > For example the raw data is as follows > > SomeText Description>PassorFail > > without spaces or new lines. I need this to be written into an XML > file as > [same content but nicely indented] Is the file supposed to be processe

Re: Convert raw data to XML

2007-01-29 Thread Justin Ezequiel
On Jan 30, 10:42 am, [EMAIL PROTECTED] wrote: > For example the raw data is as follows > > SomeText Description>PassorFail > > without spaces or new lines. I need this to be written into an XML > file as > > > > > > > SomeText >