Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Install Python + Eric IDE


Install Python Eric IDE
1 Download following things
 
1) Python3.1
 
2) PyQt for python 3.1
(http://www.riverbankcomputing.co.uk/software/pyqt/download) I am using
PyQt-Py3.1-gpl-4.7.3-2.exe
 
3) Eric5 IDE
(http://eric-ide.python-projects.org/eric-download.html)
 
2 Install python3.1
 
3 Install PyQt
 
4 Extract eric5 zip and run install.py, it will generate more file in
the eric5 folder, run eric4.bat to start eric5 IDE
 
5 The first time you run eric, configuration window will popup.
 
1) select "APIs" node,
select "Compile APIs automatically", select "python" in the
"language" list, click "Add from installed APIs", and then
select "eric5.api", and then click "Compile APIs", click "Apply"
finally.
 
 
2) select
"Autocompletion" node, select "Autocompletion Enabled",
"Case sensitive" and "Replace word"
 
 
3) select "Autocompletion
> QScintilla" node, select "from Document and API files"
 
 
4) click "OK"
 
6 Restart Eric 5 IDE


Ïà¹ØÎĵµ£º

Python ÏÂÔØÍøÒ³µÄ¼¸ÖÖ·½·¨

×ܽáÏ£¬Python ÏÂÔØÍøÒ³µÄ¼¸ÖÖ·½·¨
1
 fd = urllib2.urlopen(url_link)
 data = fd.read()
 ÕâÊÇ×î¼ò½àµÄÒ»ÖÖ£¬µ±È»Ò²ÊÇGetµÄ·½·¨
2
ͨ¹ýGETµÄ·½·¨
def GetHtmlSource(url):
    try:
   
        htmSource = ''
 &nb ......

ÈçºÎÔËÐÐPython½Å±¾

¼ÙÉèÄãÄãµÄ²Ù×÷ϵͳÊÇWinXP£º

¿ªÊ¼²Ëµ¥-> ÔËÐÐ-> cmd

È»ºó¾Í¿ÉÒÔÇÃÃüÁîÁË¡£

Èç¹ûÄãÓÃIDLE£¬¿ÉÒÔÓÃIDLE´ò¿ªÕâ¸ö.pyÎļþ£¬È»ºóÔڲ˵¥ "Run "ÏÂÓÐÒ»Ïî "Run   Module "£¬µã»÷¼´¿É¡£ ......

python¸Ä±äÎļþ¼°Æä×ÓĿ¼µÄÊôÐÔ


1.¸Ä±ä±¾ÎļþµÄÊôÐÔ
import
os
import
stat
os.chmod( filename, stat.S_IWRITE )
2.¸Ä±ä±¾Ä¿Â¼¼°Æä×ÓĿ¼ÊôÐÔ
import
os
os.system(r
'
attrib -r' + path +'\\*.* /s
'
)
3.½éÉܸıäÎļþÊôÐÔµÄdosÖ¸Áî
Attrib
ÏÔʾ¡¢ÉèÖûòɾ³ýÖ¸ÅɸøÎļþ»òĿ¼µÄÖ»¶Á¡¢´æµµ¡¢ÏµÍ³ÒÔ¼°Òþ²ØÊôÐÔ¡£Èç¹ûÔÚ²»º¬²ÎÊýµÄÇ ......

Eclipse Python¿ª·¢»·¾³

1£¬ÏÂÔØorg.python.pydev.feature-1.5.0.1251989166.zip http://sourceforge.net/projects/pydev/files/
2£¬°²×°²å¼þµ½eclipse
3£¬ÖØÆôeclipse
×¢Ò⣺ʹÓÃ1.5.6°æ±¾pydev²å¼þ£¬´´½¨python¹¤³Ì»á±¨´í£¬Ê¹ÓÃ1.5.0°æ±¾ÎÞ´ËÎÊÌâ¡£ ......

LinuxÏÂpython lxmlÄ£¿éµÄ°²×°

ÐèÒªÏÈ°²×°libxml2-devel libxslt-develÕâÁ½¸örpm°ü£¬Èç¹ûʹÓ÷ÇrootÓû§°²×°£¬¿ÉÒÔÏÂÔØlibxml2ºÍlibxsltµÄÔ´´úÂë½øÐа²×°¡£ libxml2-devel¡¢libxslt-devel×°ºÃºó£¬½âѹlxmlµÄ°ü£¬Çл»µ½Õâ¸ö°üµÄ·¾¶¡£
¼ÓÈëCFLAGS½øÐбàÒëºÍ°²×°£¬ÔÚshellÏÂÒÀ´ÎÊäÈëÈçÏÂÃüÁ CFLAGS=-I/usr/include/libxml2:/usr/include/libxslt/ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ