Re: [web2py] Re: Web3py

2019-04-17 Thread Massimo Di Pierro
Ignorance on my side. If you want to make a PR switching to vuetify I will accept it. On Wednesday, 17 April 2019 02:17:49 UTC-7, Ramos wrote: > > Massimo , any reason you chose Bulma instead of vuetify ? > Vuetify is designed specifically for vuejs > Regards > António > > Em qua, 17 de abr de

[web2py] Re: Asynchronous submission of request.vars values to Controller for calculations using Ajax

2019-04-17 Thread Paul Ellis
Which controller is displaying the view you have posted? It looks like the ajax function is calling the same controller which returns the index page. The controller function called by the ajax function should return a string. The string can be jquery which will be evaluated if you use ':eval'.

[web2py] Re: Converting large app from Python2 to Python3 - how do you handle code in views ?

2019-04-17 Thread Leonel Câmara
You can look at yatl code. https://github.com/web2py/yatl To see how web2py does it. But frankly I doubt you have much python 3 incompatible code in your views, I would just test them as they are, they're probably fine. -- Resources: - http://web2py.com - http://web2py.com/book

[web2py] Re: Does web2py support SSE (server sent events) from HTML5?

2019-04-17 Thread Carlos Zenteno
following -- 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"

Re: [web2py] Asynchronous submission of request.vars values to Controller for calculations using Ajax

2019-04-17 Thread António Ramos
post a screenshot of your error and code... Em qua, 17 de abr de 2019 às 17:51, mostwanted escreveu: > I have seriously fiddled with docs code trying to bend it to my will but > its not obliging, maybe its my limited programming skills but thanks for > replying Ramos. > > Mostwanted > > -- >

[web2py] Re: How can I return a report to the user in the view?

2019-04-17 Thread Leonel Câmara
You have to either convert those '\n' into or paragraph tags by doing something like this in the view {{=DIV(*[P(line) for line in report.split('\n')])}} or put the report inside a PRE tag to tell the browser the text comes preformatted {{=form}} {{=report}} -- Resources: -

Re: [web2py] Asynchronous submission of request.vars values to Controller for calculations using Ajax

2019-04-17 Thread mostwanted
I have seriously fiddled with docs code trying to bend it to my will but its not obliging, maybe its my limited programming skills but thanks for replying Ramos. Mostwanted -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source

Re: [web2py] Asynchronous submission of request.vars values to Controller for calculations using Ajax

2019-04-17 Thread António Ramos
try this from the docs... then change it accordingly to your needs def one(): return dict() def echo(): return request.vars.name and the associated "default/one.html" view: {{extend 'layout.html'}} Em qua, 17 de abr de 2019 às 13:47, mostwanted escreveu: > I understand what u

[web2py] Re: howto prevent XSS in json data

2019-04-17 Thread Leonel Câmara
Please open an issue, you're right, this is a bug and a security problem, it's also very easy to fix by simply copy pasting escapejs from django. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) -

Re: [web2py] Asynchronous submission of request.vars values to Controller for calculations using Ajax

2019-04-17 Thread mostwanted
I understand what u are saying, how can i achieve what i am trying to achieve this? Submit values to a controller without refreshing a page? On Wednesday, April 17, 2019 at 1:58:56 PM UTC+2, Ramos wrote: > > > > http://www.web2py.com/books/default/chapter/29/11/jquery-and-ajax#The-ajax-function

[web2py] Re: Problem with admin debugger still in 2.17.1

2019-04-17 Thread David Manns
This is still not fixed in 2.18.5. Breakpoint only works first time. After continuing, the code runs at full speed but the breakpoint won't trigger again. Clearing breakpoint in the admin screen and re-adding it makes no difference. Clearing removes the breakpoint from the admin screen but puts

Re: [web2py] Asynchronous submission of request.vars values to Controller for calculations using Ajax

2019-04-17 Thread António Ramos
http://www.web2py.com/books/default/chapter/29/11/jquery-and-ajax#The-ajax-function Note the diference between :eval and the 'target' id alternative If you use eval than you have to return not locals() but a string with javascript to be evaluated like for example jQuery('#target').html('100');

[web2py] Asynchronous submission of request.vars values to Controller for calculations using Ajax

2019-04-17 Thread mostwanted
I am trying to do something that is supposed to be relatively simple, i want to submit a value through a form to a controller for calculations using ajax so that the page doesn't refresh but i am not getting any results back in my view, i changed the way of doing that using ajax just a-little

[web2py] Re: one form multiple submits

2019-04-17 Thread Dave S
On Tuesday, April 16, 2019 at 6:46:52 PM UTC-7, Dave S wrote: > > > > On Tuesday, April 16, 2019 at 2:56:53 PM UTC-7, Ben Lawrence wrote: >> >> The _value is the word that appears inside the button on the web-page. It >> seems "Working..." is the value in form.vars where the key is _name. >> >>

Re: [web2py] Re: Web3py

2019-04-17 Thread António Ramos
found it self.start = function() { *Vue.config.devtools = true;* self.vue = new Vue({el: '#vue', data: self.data, methods: self.methods, filters: self.filters}); self.on_load(); }; Em qua, 17 de abr de 2019 às 10:38, António Ramos escreveu: > How to use vue

Re: [web2py] Re: Web3py

2019-04-17 Thread António Ramos
How to use vue devtools? Vue.js is detected on this page. Devtools inspection is not available because it's in production mode or explicitly disabled by the author. Em qua, 17 de abr de 2019 às 10:17, António Ramos escreveu: > Massimo , any reason you chose Bulma instead of vuetify ? > Vuetify

Re: [web2py] Re: Web3py

2019-04-17 Thread António Ramos
Massimo , any reason you chose Bulma instead of vuetify ? Vuetify is designed specifically for vuejs Regards António Em qua, 17 de abr de 2019 às 09:37, António Ramos escreveu: > Worked for me... > > > Em ter, 16 de abr de 2019 às 21:32, En Ware escreveu: > >> Thank you , that did it. >> >> On

[web2py] Re: SQLTABLE and SQLFORM.grid with PRE()

2019-04-17 Thread Dave S
On Monday, April 15, 2019 at 11:37:36 PM UTC-7, Dave S wrote: > > > > On Monday, April 15, 2019 at 10:51:17 PM UTC-7, Massimo Di Pierro wrote: >> >> db.table.field.represent = lambda value, row: PRE(value) >> >> > Obvious now! Thank you much. > > /dps > While this worked very well, the PRE class

Re: [web2py] Re: Web3py

2019-04-17 Thread António Ramos
Worked for me... Em ter, 16 de abr de 2019 às 21:32, En Ware escreveu: > Thank you , that did it. > > On Tuesday, April 16, 2019 at 2:42:40 PM UTC-5, Massimo Di Pierro wrote: >> >> You have an old pydal. Do >> >> pip3 install --upgrade pydal >> >> Also do >> >> python3 web3py.py applications

[web2py] Re: Does web2py support SSE (server sent events) from HTML5?

2019-04-17 Thread João Matos
Thanks Anthony. quarta-feira, 17 de Abril de 2019 às 03:23:50 UTC+1, Anthony escreveu: > > On Tuesday, April 16, 2019 at 11:14:10 AM UTC-4, João Matos wrote: >> >> Thanks Anthony, but I'm using Apache. >> >> Do you know any current solution for Apache? >> > > You should be able to run Centrifugo

[web2py] Re: CORS headers on static file

2019-04-17 Thread Massimo Di Pierro
The usual process for CORS is to put web2py behind nginx and configure nginx for CORS On Tuesday, 16 April 2019 03:45:28 UTC-7, David Orme wrote: > > Hi, > > I'm running a static website from an S3 bucket that calls an API running > on web2py and I've run into a problem with CORS. I can update

[web2py] Re: Controller/function called via ajax() returns javascript inside JS

2019-04-17 Thread Massimo Di Pierro
Not enough information. can you post a more complete example we can run? On Tuesday, 16 April 2019 02:26:13 UTC-7, Octavian G wrote: > > Hello, > > Using web2py-1.18.5. Calling a controller/function via: > > onclick="ajax('{{=URL('bla', 'bla.load', vars={'whatever': 'all'})}}', > [],