how could I get all email address in a html page?
how could I get all email address in a html page? Have any modle can do this? like the htmldata.urlextract . -- http://mail.python.org/mailman/listinfo/python-list
how to download a zip or rar file to local machine using python?
I wrote as following:
content=urllib2.urlopen("http://www.sdfagfa.org/asasg/a.zip";).read()
f=open("d:\\a.zip",'a+',1)
f.writelines(content)
the zip file has been download to my machine,but when be unzip , error
occurs:
" there is an error at the end of the file"
--
http://mail.python.org/mailman/listinfo/python-list
Re: how to download a zip or rar file to local machine using python?
thank james;
and I have got a way to resolve it :
urllib.urlretrieve('http://x.x.x.x/library.zip','library.zip')
--
http://mail.python.org/mailman/listinfo/python-list
Re: how to download a zip or rar file to local machine using python?
but I want to ask: how to find out explaination about the parameters of 'open()' function? -- http://mail.python.org/mailman/listinfo/python-list
Re: how to download a zip or rar file to local machine using python?
thanks a lot. -- http://mail.python.org/mailman/listinfo/python-list
Can't get the real contents form page in internet as the tag "no-chche"
using web browser can get page's content formally, but when use
urllib2.open("http://tech.163.com/2004w11/12732/2004w11_1100059465339.html";).read()
the result is
http://tech.163.com/04/1110/12/14QUR2BR0009159H.html";>
?y?ú'ò?aò3??...
,I think the reson is the no-cache, are there person would help me?
--
http://mail.python.org/mailman/listinfo/python-list
Re: Can't get the real contents form page in internet as the tag "no-chche"
yeah,u r right, the page uses chinese.(I'm a chinese too.^_^,)
using urllib2.urlopen('').read(),I can't get the contents
between '' and '' ,the reason isn't the chinese encoding
but the 'no-cache' set,I think.
I want to get the contents between
can you find the problem why i can't read the contents? thanks.
--
http://mail.python.org/mailman/listinfo/python-list
Re: Can't get the real contents form page in internet as the tag "no-chche"
oh~~~! offer my thanks to Tim Roberts and all persons above! I see now, it's the different url causes! contents can only be got from the later (real ) url. I made a mistick not to look at the different urls taking effect. -- http://mail.python.org/mailman/listinfo/python-list
question: how to clare the absolute url in a html file
is there any lib to help to clear the absolute url in a html file? for example, 'http://www.sina.com/' should be clear ,but "/image/asd.gif" should be reserved. -- http://mail.python.org/mailman/listinfo/python-list
Re: question: how to clare the absolute url in a html file
to Diez B. Roggisch : no, I won't to use this way, its efficiency is very low as I need to replace all the 'http://mail.python.org/mailman/listinfo/python-list
how to format a return value by using re.sub(regx,rep1,str)?
for example:
re.sub(']+)+\s?>[^<^>]*','',' asd gahttp://www.sine.com"; class="wordstyle"> asdgasdghae rha')
I wish to get the return value "asd ga asdgasdghae rha",how do do?
I have a impression on "%" and "{number}",but forgot how to use them.
--
http://mail.python.org/mailman/listinfo/python-list
