Re: Splitting SAX results

2007-06-20 Thread Stefan Behnel
Gabriel Genellina wrote: > Forget about SAX. Use ElementTree instead > ElementTree is infinitely more flexible and easier to use. > See That's what I told him/her already :) Rephrasing a famous word: Being faced with an XML problem, you might think "Ok,

Re: Splitting SAX results

2007-06-12 Thread Gabriel Genellina
En Tue, 12 Jun 2007 16:16:45 -0300, IamIan <[EMAIL PROTECTED]> escribió: > I do know how split works, but thank you for the response. The end > result that I want is a dictionary made up of the title results coming > through SAX, looking like {'Title1: Description', > 'Title2:Description'}. > > Th

Re: Splitting SAX results

2007-06-12 Thread IamIan
I do know how split works, but thank you for the response. The end result that I want is a dictionary made up of the title results coming through SAX, looking like {'Title1: Description', 'Title2:Description'}. The XML data looks like: Title1:Description Link Desc Author Date Title2:Description

Re: Splitting SAX results

2007-06-08 Thread Jerry Hill
On 6/8/07, IamIan <[EMAIL PROTECTED]> wrote: > Well SAX isn't the problem... maybe I should repost this with a > different title. The SAX part works just as I want, but the results I > get back need to be manipulated. No matter what I try I can't split a > result like 'Title 1:Description' on the c

Re: Splitting SAX results

2007-06-08 Thread IamIan
Well SAX isn't the problem... maybe I should repost this with a different title. The SAX part works just as I want, but the results I get back need to be manipulated. No matter what I try I can't split a result like 'Title 1:Description' on the colon without getting an IndexError. Ideas anyone? --

Re: Splitting SAX results

2007-06-06 Thread Stefan Behnel
IamIan wrote: > I have a very simple SAX script from which I get results like > 'Title1:Description','Title2:Description'. I want to split each result > on the colon, using the two resulting elements as key/value pairs in a > dictionary. I've tried a couple different approaches with lists etc, > bu

Splitting SAX results

2007-06-06 Thread IamIan
Hi list, I have a very simple SAX script from which I get results like 'Title1:Description','Title2:Description'. I want to split each result on the colon, using the two resulting elements as key/value pairs in a dictionary. I've tried a couple different approaches with lists etc, but I keep getti