Hackfut Security File Manager
Current Path:
/usr/lib64/python2.6/site-packages/meld3
usr
/
lib64
/
python2.6
/
site-packages
/
meld3
/
📁
..
📄
__init__.py
(156 B)
📄
__init__.pyc
(334 B)
📄
__init__.pyo
(334 B)
📄
clearsilverprofile.py
(1.61 KB)
📄
clearsilverprofile.pyc
(2.13 KB)
📄
clearsilverprofile.pyo
(2.13 KB)
📄
cmeld3.so
(11.09 KB)
📄
example.py
(1.51 KB)
📄
example.pyc
(1.78 KB)
📄
example.pyo
(1.78 KB)
📄
meld3.py
(49.47 KB)
📄
meld3.pyc
(47.15 KB)
📄
meld3.pyo
(47.15 KB)
📄
melddiff.py
(620 B)
📄
melddiff.pyc
(999 B)
📄
melddiff.pyo
(999 B)
📄
meldprofile.py
(1.73 KB)
📄
meldprofile.pyc
(2.18 KB)
📄
meldprofile.pyo
(2.18 KB)
📄
test_getiterator.py
(1.21 KB)
📄
test_getiterator.pyc
(1.93 KB)
📄
test_getiterator.pyo
(1.93 KB)
📄
test_meld3.py
(60.62 KB)
📄
test_meld3.pyc
(62.33 KB)
📄
test_meld3.pyo
(62.33 KB)
📄
testclone.py
(1.3 KB)
📄
testclone.pyc
(1.5 KB)
📄
testclone.pyo
(1.5 KB)
📄
zptprofile.py
(1.93 KB)
📄
zptprofile.pyc
(3.37 KB)
📄
zptprofile.pyo
(3.37 KB)
Editing: example.py
xml = """<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:meld="http://www.plope.com/software/meld3" xmlns:bar="http://foo/bar"> <head> <meta content="text/html; charset=ISO-8859-1" http-equiv="content-type" /> <title meld:id="title">This is the title</title> </head> <body> <div/> <!-- empty tag --> <div meld:id="content_well"> <form meld:id="form1" action="." method="POST"> <table border="0" meld:id="table1"> <tbody meld:id="tbody"> <tr> <th>Name</th> <th>Description</th> </tr> <tr meld:id="tr" class="foo"> <td meld:id="td1">Name</td> <td meld:id="td2">Description</td> </tr> </tbody> </table> <input type="submit" name="next" value=" Next "/> </form> </div> </body> </html> """ from meld3 import parse_xmlstring from meld3 import parse_htmlstring from StringIO import StringIO import sys root = parse_xmlstring(xml) root.findmeld('title').content('My document') root.findmeld('form1').attributes(action='./handler') data = ( {'name':'Boys', 'description':'Ugly'}, {'name':'Girls', 'description':'Pretty'}, ) iterator = root.findmeld('tr').repeat(data) for element, item in iterator: element.findmeld('td1').content(item['name']) element.findmeld('td2').content(item['description']) root.write_xhtml(sys.stdout)
Upload File
Create Folder