spaces from a web form
Rakotomandimby Mihamina <[email protected]> Thu, 23 Jul 2009 06:49:52 +0300
| Newsgroups | gmane.comp.python.mod_python |
|---|---|
| Message-ID | <[email protected]> |
Hi all
let the following simplified code be:
import re
textarea=for.getfirst('text')
spaces=re.compile('^( )+$')
new_txt=re.sub(spaces, '_', textarea)
The HTML is a very simple form with a textarea.
The substitution doesnt occur. The '+' signs
in the Url seem to be stripped and replaced by
something not matched as a space;
I already tried with something like "\s" in the regexp
but no more luck. Any more tips?
Thank you.
--
Architecte Informatique:
Administration Systeme, Recherche & Developpement
+ 261 32 11 401 65
Pensez a l'environnement avant d'imprimer ce message