web2py™ | Version 2.9.11-stable+timestamp.2014.09.15.23.35.11 |
---|---|
Python | Python 2.7.8: c:\python27\python.exe (prefix: c:\python27) |
1. | Traceback (most recent call last): |
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups "web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to web2py+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Well globals in Python are really only global to their own module, web2py templates and controllers are not exactly python modules anyway, so, it's complicated; just do it in the view and let the template system take care of it.
--
Richard D again ;)
import defaults from 'config/defaults/options';import easing from 'config/defaults/easing';import interpolators from 'config/defaults/interpolators';
{{ractive_enabled=True}}{{extend 'layout.html'}}<div id='main'></div><script id='main-template' type='text/ractive'><p>Hello, [[name]]!</p></script>
<script>var ractive = new Ractive({el: '#main',template: '#main-template',delimiters: [ '[[', ']]' ],tripleDelimiters: [ '[[[', ']]]' ] ,});</script>
--
db = DAL('sqlite://storage.sqlite',pool_size=1) #,check_reserved=['all'])
{{ractive_enabled=True}}
{{extend 'layout.html'}}
<div id='main'></div>
<script id='main-template' type='text/ractive'>
<p>Hello, [[name]]!</p>
</script>
<script>
var ractive = new Ractive({
el: '#main',
template: '#main-template',
delimiters: [ '[[', ']]' ],
tripleDelimiters: [ '[[[', ']]]' ] ,
});
</script>
{{if ractive_enabled:}}
<script id="main-template" type='text/ractive'>
{{else:}}
<main id="main" class="main row" role="main">
{{pass}}
{{if left_sidebar_enabled:}}
<div class="col-lg-3 col-md-3 left-sidebar sidebar">
{{block left_sidebar}}
<h3>Left Sidebar</h3>
<p></p>
{{end}}
</div>
{{pass}}
<div class="{{=middle_columns}}">
{{block center}}
{{include}}
{{end}}
</div>
{{if right_sidebar_enabled:}}
<div class="col-lg-3 col-md-3 right-sidebar sidebar">
{{block right_sidebar}}
<h3>Right Sidebar</h3>
<p></p>
{{end}}
</div>
{{pass}}
{{if ractive_enabled:}}
</script>
<main id="main" class="main row" role="main">
{{pass}}
</main><!--/main-->
Would help too!
To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscribe@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to web2py+un...@googlegroups.com.
Please look into this: https://github.com/mdipierro/w3I could very much use your opinions. I am working on it actively these days.
--
To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscribe@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to web2py+un...@googlegroups.com.
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups "web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to web2py+un...@googlegroups.com.