Efficient string manipulation , Help please

Darrell news at dorb.com
Thu Jul 8 12:58:16 EDT 1999


SGML gets around these kinds of problems with entities.
http://www.topdat.com/java/html/SGML/ENTITIES.HTM

Entities are like macros.
< defines <
> defines >
" defines "

I'm suggesting that you replace the offending symbols as they come in with
an entity.
And replace the entities when you output the text.

Of course I have almost no idea about the details of your problem.
--
--Darrell
Sreekant Kodela <sreekantk at freenet.co.uk> wrote in message
news:37856BF1.BD046003 at freenet.co.uk...
>
> Dear all
>
> I seem to be in trouble here. I am trying to make some cgi scripts for
> my web site. I am using the postgresql as the backend db and a form
> based address book and news forum etc. The problem is everything is
> working ok as long as noone uses ' and " in the text. If they do, bingo
> , postgres refuses to accept. I tried using string library [mainly
> string.join(string.split('awkward'"'st'ring')). It works sometimes and
> doesn't some times.
>
> Any better and efficient way to deal with this situation !
>
> Any suggestions and ideas will be greatly appreciated.
>
> Thanks
> sreekant
>
>
>






More information about the Python-list mailing list