For a compelling (and humorous) argument of why NOT to use Regex to parse
XML/HTML, read this SO nugget:
http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags
Seriously, it's my favorite SO post ever. Enjoy!
On Wednesday, December 11, 2013 8:47:42 PM
LOL
On Thursday, 12 December 2013 17:08:44 UTC-6, AbrahamLinksys wrote:
For a compelling (and humorous) argument of why NOT to use Regex to parse
XML/HTML, read this SO nugget:
http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags
Seriously,
use response.stream
Quarta-feira, 11 de Dezembro de 2013 0:11:46 UTC, Cliff escreveu:
Hello.
I am new to both python and web2py but have been playing with it a bit. I
have made a simple program to listen to like artists from lastfm's API. I
store my mp3s in a database: Artist/Track/File.
I seen the documentation from the book on web2py.com but I am unsure how I
would use response.stream. Could you give me an example please? Here is the
current code I am using.
HTML
{{for item in printrows:}}
{
title:{{=item[0][2]}},
Heres an example
def stream():
Stream an mp3 from an absolute path given as var
WARNING: This is definitely unsafe as it doesn't care what that path is
at all.
WARNING: Seriously this is just an example, don't use it.
import os
if os.path.exists(request.vars.path)::
That was very helpful. I can now hear music! The regex so far has just been
working so I haven't messed with it. Thanks for the suggestion, I will look
into better ways to manage the XML.
Thanks Leonel!
On Wednesday, December 11, 2013 7:08:11 PM UTC-5, Leonel Câmara wrote:
Heres an example
6 matches
Mail list logo