[XML-SIG] find and replace

Eric Chao ericchao0613 at gmail.com
Tue Jul 29 08:39:16 CEST 2008

So I've been trying to find and replace some text with python using regular
expression, but I haven't been able to make permanent changes and just to
the files.

-this is the data in the original file.

@#$The Creation@#$%
{{01:1}}1 In the beginning God created the heavens and the earth.
{{01:1}}2 The earth was <$FOr {a waste and emptiness}>>formless and void,
and darkness was over the surface of the deep, and the Spirit of God was
<$FOr {hovering}>>moving over the surface of the waters.
{{01:1}}3 Then God said, ``Let there be light"; and there was light.
{{01:1}}4 God saw that the light was good; and God separated the light from
the darkness.

-I want to replace @#$ with <title> and <@#$%> with </title> using python.

After I replace a few elements, I can start creating xml.

Can anyone offer some insight as to how to do this ? It would be greatly
appreciated. Thanks !

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/xml-sig/attachments/20080729/fefcf802/attachment.htm>

More information about the XML-SIG mailing list