Improved form in stream and corrected a bug in web.py
This commit is contained in:
parent
7b98fe724b
commit
8f923cb757
|
@ -8,7 +8,7 @@
|
|||
<p>
|
||||
You can try with a different resolution (between 1 and 25)
|
||||
<form action="" method="GET">
|
||||
Resolution : <input id="res" name="res" type="number" min="1" max="25" value="5" length=10/>
|
||||
Resolution : <input id="res" name="res" type="number" min="1" max="25" value="%(res)s" length=10/>
|
||||
<input type="submit" value="Go !" />
|
||||
</form>
|
||||
</p>
|
||||
|
|
|
@ -42,7 +42,7 @@ def main():
|
|||
body.add_child(jsIncludes)
|
||||
jsIncludes.add_child(mainJs)
|
||||
|
||||
page.print()
|
||||
page.print({'res' : res})
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
|
@ -40,7 +40,7 @@ class Element:
|
|||
self.children.append(child)
|
||||
|
||||
def print(self, format = {}):
|
||||
self.open()
|
||||
self.open(format)
|
||||
for i in self.children:
|
||||
i.print(format)
|
||||
self.close()
|
||||
self.close(format)
|
||||
|
|
Loading…
Reference in New Issue