[web2py] Include control specific data in layout.html header

2020-04-01 Thread Jon Subscripted
Hi everyone, I'm trying to include view specific data in each view header (it is actually a GTM datalayer). I thought the best way to do it was to define a global variable in db.py and to print a variable {{=datalayer}}, the each controller will overwrite it with specific data. It seems to be

[web2py] Re: Embed youtube video in markmin (à la web2py book)

2020-04-01 Thread Jon Subscripted
Hi, any suggestions on how to implement this? Thanks, Jon. On Tue, Mar 31, 2020 at 2:00 PM Jon Subscripted wrote: > Hi everyone, > I have a part of my website shaped as web2py book. In order to handle long > texts in different languages. > > As you might know content is in *.markmin files that

[web2py] Re: Include control specific data in layout.html header

2020-04-01 Thread Jon Subscripted
Hi everyone, I've just realized what I was doing wrong. What happened is that I was not returning locals(), but a custom dict, which was not updated. Right implementation: def index(): datalayer = get_datalayer('general','index') return locals() Wrong implementation: def index():

[web2py] Re: jQuery not working with web2py

2020-04-01 Thread Maurice Waka
Any help on this? I can't get the code to work with jQuery {{extend 'layout.html'}} /*QuickReset*/ *{margin:0;box-sizing:border-box;} html,body{height:100%;font:14px/1.4 sans -serif;} article { height: 150vh; } WELCOME (wait 3 sec) ABOUT OUR

[web2py] Re: jQuery not working with web2py

2020-04-01 Thread Jim S
What errors are you seeing in your browser console? -Jim On Wednesday, April 1, 2020 at 4:56:07 PM UTC-5, Maurice Waka wrote: > > Any help on this? > I can't get the code to work with jQuery > > {{extend 'layout.html'}} > > > > > > > > > > > > > > > > /*QuickReset*/ >

Re: [web2py] Re: jQuery not working with web2py

2020-04-01 Thread Maurice Waka
On page reload it should ; ... Slide to testimonials then after 3 seconds Slide to contact. In Web2py nothing happens. When I do it from the folder it works. Do the error is that it doesn't slide as normal Regards On Thu, Apr 2, 2020, 03:54 Jim S wrote: > What errors are you seeing in

Re: [web2py] Re: jQuery not working with web2py

2020-04-01 Thread Maurice Waka
I don't have firefox but on opera & chrome it gives this: web2py-bootstrap3.js:2 Uncaught TypeError: Cannot set property 'ajax_fields' of undefined at web2py-bootstrap3.js:2 at web2py-bootstrap3.js:82 On Thursday, April 2, 2020 at 6:17:36 AM UTC+3, Jim S wrote: > > But have you looked

Re: [web2py] Re: jQuery not working with web2py

2020-04-01 Thread Jim Steil
But have you looked at the browser JavaScript console to see what it is telling you? In Firefox press F12 and then click on the console tab. That will tell you what JavaScript errors are occurring in the browser. Jim On Wed, Apr 1, 2020, 9:35 PM Maurice Waka wrote: > On page reload it should