projects
/
treecutter.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b2628a0
)
Adding initial support for html forms.
author
Fredrik Unger
<fred@tree.se>
Mon, 6 Feb 2012 21:17:06 +0000
(22:17 +0100)
committer
Fredrik Unger
<fred@tree.se>
Mon, 6 Feb 2012 21:17:06 +0000
(22:17 +0100)
src/tree-cutter.py
patch
|
blob
|
history
diff --git
a/src/tree-cutter.py
b/src/tree-cutter.py
index 19ddd87ab32116dbc9596a265961f0dc6d27e66c..1daed02116dc72cd6882d3bb04617038fce2fab5 100755
(executable)
--- a/
src/tree-cutter.py
+++ b/
src/tree-cutter.py
@@
-49,7
+49,8
@@
def publish(src,target):
PREFIXES={u'db': u'http://docbook.org/ns/docbook',
u'xi': u'http://www.w3.org/2001/XInclude',
PREFIXES={u'db': u'http://docbook.org/ns/docbook',
u'xi': u'http://www.w3.org/2001/XInclude',
- u'xl': u'http://www.w3.org/1999/xlink'}
+ u'xl': u'http://www.w3.org/1999/xlink',
+ u'html' : u'http://www.w3.org/1999/xhtml'}
class Directory():
"""Class containing the state of the directory with articles"""
class Directory():
"""Class containing the state of the directory with articles"""
@@
-126,6
+127,11
@@
class Page():
im = os.path.join(dirname,i.fileref)
if os.path.isfile(im):
self._resources.append(im)
im = os.path.join(dirname,i.fileref)
if os.path.isfile(im):
self._resources.append(im)
+ for i in self._doc.xml_select(u"//html:form[@action]"):
+ pyscript = re.split('\.py',i.action,1)[0]+'.py'
+ im = os.path.join(dirname,pyscript)
+ if os.path.isfile(im):
+ self._resources.append(im)
def render(self):
# amara can not handle the docbook stylesheets
def render(self):
# amara can not handle the docbook stylesheets