![]() |
Available news archives:
comp.lang.tcl
-
comp.lang.python
-
comp.security.firewalls
-
sci.crypt -
comp.lang.php -
comp.lang.javascript
|
|
comp.lang.python archiveSplitting on a word
From: <qwweeeit@yahoo.it>
Date: Wed Jul 13 2005 - 15:19:54 CEST
Hi all,
I am asking if there is some alternative (more pythonic...):
# SplitMultichar.py
import re
# string s simulating an html file
lHref=p.findall(s) # lHref=['href','HREF']
c='~' # char to be used as delimiter
# s ='ffy: ytrty <a ~="www.python.org">python</a> fyt <A
list=s.split(c)
If you save the original s string to xxx.html, any browser
|