Re: [web2py] Re: LOAD in py4web

2022-02-17 Thread cdbaron
Thanks a lot.

I'll try load_and_trap, but I think htmx may be better. I will look at your 
applications.

El jueves, 17 de febrero de 2022 a las 0:10:33 UTC+1, Jim S escribió:

> See this thread for how to replicate LOAD in py4web - 
> https://groups.google.com/u/1/g/py4web/c/EUpv9IRJ_eo/m/niHzrnR5AwAJ
>
> In short, use load_and_trap from utils.js.
>
> I was using this for a while but then transitioned to doing all my 
> reactive-type functions using htmx.  https://htmx.org
>
> Check out my py4web htmx demo - 
> https://github.com/jpsteil/py4web_htmx_demo
>
> or my sample SouthBreeze application 
> https://github.com/jpsteil/southbreeze  for examples.
>
> htmx is amazing
>
> NOTE - demos might now work with the latest py4web from github.  There are 
> some changes I need to apply to my code that I haven't gotten to yet.
>
> Can anyone else address the "A" and "URL" questions?
>
> -Jim
>
>
> On Tuesday, February 15, 2022 at 3:47:24 PM UTC-6 cdbaron wrote:
>
>> I have several projects with web2py and I have already started to study 
>> the possibility of migrating to py4web.
>>
>> They are all rendered on the server side and for now I want to keep it 
>> that way.
>>
>> I see some challenges that make me a little scared:
>>
>> *LOAD
>> * A Helper: (many times with the callback parameter and others with _href)
>> * URL: With user_signature=True for links with callback
>>
>> I use hundreds of times A and URL and a little less LOAD
>>
>> For none of these functions or helpers have I found a direct replacement 
>> in py4web.
>>
>> LOAD does not exist in py4web, A does not have the possibility of ajax 
>> calls with the callback parameter and URL is totally different in py4web.
>>
>> It would be great to see some of this web2py magic carried over to py4web.
>>
>> El domingo, 6 de febrero de 2022 a las 15:37:49 UTC+1, vinid...@gmail.com 
>> escribió:
>>
>>> Have you managed to make a welcome template based on Unpoly?
>>>
>>> On Wednesday, March 4, 2020 at 8:37:51 PM UTC+7 yamand...@gmail.com 
>>> wrote:
>>>
 Sorry for the typo.
 I want to make a welcome template based on unpoly soon.

 Em sex., 28 de fev. de 2020 às 04:21, AGRogers  
 escreveu:

> https://unpoly.com/  
>
> On Fri, 28 Feb 2020 at 16:22, Massimo Di Pierro  
> wrote:
>
>> never heard of unpolly.js and cannot find it. Have a link?
>>
>>
>> On Wednesday, 26 February 2020 19:32:20 UTC-8, Carlos Costa wrote:
>>>
>>> LOAD is a very cool thing! And beginners just say WOW when they can 
>>> create ajax-like experience so easy.
>>> But, IMO, it lacks some important features for modern apps, like 
>>> error handling and history handling.
>>>
>>> I have written some simple functions to help cover these things...
>>>
>>> Another way I found very useful was to use unpolly.js. It's magic 
>>> but makes me a little lazyer about getting things done with vue.js.
>>> (BTW they created unpolly to avoid using things like vue, react, 
>>> etc, really!)
>>>
>>> I would like very much to use vue.js but I am still noob regarding 
>>> how to use it with py4web.
>>> Maybe we should really encourage vue.js and stuff alike... but an 
>>> initial pattern would be cool.
>>> And IMO it should be simple and very cleared stated in the docs.
>>> So no one will miss LOAD.
>>>
>>> Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:

 HI,

 I am beginning to experiment with py4web, I like the sound of it 
 and I am looking to convert a web2py project to py4web to see how they 
 compare.

 It appears that the LOAD (helper?) that was available in web2py 
 templates is not available in py4web. I was using this to populate 
 part of 
 a web page, I liked the way you had the option to use LOAD to call a 
 separate URL (within the same app) and insert the result into your 
 page 
 before returning the page to the client.

 What is the reason for the absence of LOAD in py4web? is there a 
 recommended alternative method of achieving the same effect? I have 
 used a 
 mixture of ajax=True and ajax=False options for this feature.

 Thanks,

 Richard.

>>> -- 
>> 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.
>> To view this discussion on the web visit 
>> 

Re: [web2py] Re: LOAD in py4web

2022-02-16 Thread Jim S
See this thread for how to replicate LOAD in py4web - 
https://groups.google.com/u/1/g/py4web/c/EUpv9IRJ_eo/m/niHzrnR5AwAJ

In short, use load_and_trap from utils.js.

I was using this for a while but then transitioned to doing all my 
reactive-type functions using htmx.  https://htmx.org

Check out my py4web htmx demo - https://github.com/jpsteil/py4web_htmx_demo

or my sample SouthBreeze application 
https://github.com/jpsteil/southbreeze  for examples.

htmx is amazing

NOTE - demos might now work with the latest py4web from github.  There are 
some changes I need to apply to my code that I haven't gotten to yet.

Can anyone else address the "A" and "URL" questions?

-Jim


On Tuesday, February 15, 2022 at 3:47:24 PM UTC-6 cdbaron wrote:

> I have several projects with web2py and I have already started to study 
> the possibility of migrating to py4web.
>
> They are all rendered on the server side and for now I want to keep it 
> that way.
>
> I see some challenges that make me a little scared:
>
> *LOAD
> * A Helper: (many times with the callback parameter and others with _href)
> * URL: With user_signature=True for links with callback
>
> I use hundreds of times A and URL and a little less LOAD
>
> For none of these functions or helpers have I found a direct replacement 
> in py4web.
>
> LOAD does not exist in py4web, A does not have the possibility of ajax 
> calls with the callback parameter and URL is totally different in py4web.
>
> It would be great to see some of this web2py magic carried over to py4web.
>
> El domingo, 6 de febrero de 2022 a las 15:37:49 UTC+1, vinid...@gmail.com 
> escribió:
>
>> Have you managed to make a welcome template based on Unpoly?
>>
>> On Wednesday, March 4, 2020 at 8:37:51 PM UTC+7 yamand...@gmail.com 
>> wrote:
>>
>>> Sorry for the typo.
>>> I want to make a welcome template based on unpoly soon.
>>>
>>> Em sex., 28 de fev. de 2020 às 04:21, AGRogers  
>>> escreveu:
>>>
 https://unpoly.com/  

 On Fri, 28 Feb 2020 at 16:22, Massimo Di Pierro  
 wrote:

> never heard of unpolly.js and cannot find it. Have a link?
>
>
> On Wednesday, 26 February 2020 19:32:20 UTC-8, Carlos Costa wrote:
>>
>> LOAD is a very cool thing! And beginners just say WOW when they can 
>> create ajax-like experience so easy.
>> But, IMO, it lacks some important features for modern apps, like 
>> error handling and history handling.
>>
>> I have written some simple functions to help cover these things...
>>
>> Another way I found very useful was to use unpolly.js. It's magic but 
>> makes me a little lazyer about getting things done with vue.js.
>> (BTW they created unpolly to avoid using things like vue, react, etc, 
>> really!)
>>
>> I would like very much to use vue.js but I am still noob regarding 
>> how to use it with py4web.
>> Maybe we should really encourage vue.js and stuff alike... but an 
>> initial pattern would be cool.
>> And IMO it should be simple and very cleared stated in the docs.
>> So no one will miss LOAD.
>>
>> Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:
>>>
>>> HI,
>>>
>>> I am beginning to experiment with py4web, I like the sound of it and 
>>> I am looking to convert a web2py project to py4web to see how they 
>>> compare.
>>>
>>> It appears that the LOAD (helper?) that was available in web2py 
>>> templates is not available in py4web. I was using this to populate part 
>>> of 
>>> a web page, I liked the way you had the option to use LOAD to call a 
>>> separate URL (within the same app) and insert the result into your page 
>>> before returning the page to the client.
>>>
>>> What is the reason for the absence of LOAD in py4web? is there a 
>>> recommended alternative method of achieving the same effect? I have 
>>> used a 
>>> mixture of ajax=True and ajax=False options for this feature.
>>>
>>> Thanks,
>>>
>>> Richard.
>>>
>> -- 
> 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.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/web2py/22d8b9cf-9ce2-464b-809e-32d4dd84fd02%40googlegroups.com
>  
> 
> .
>
 -- 
 Resources:
 - http://web2py.com
 - http://web2py.com/book (Documentation)
 - http://github.com/web2py/web2py (Source code)

Re: [web2py] Re: LOAD in py4web

2022-02-15 Thread cdbaron
I have several projects with web2py and I have already started to study the 
possibility of migrating to py4web.

They are all rendered on the server side and for now I want to keep it that 
way.

I see some challenges that make me a little scared:

*LOAD
* A Helper: (many times with the callback parameter and others with _href)
* URL: With user_signature=True for links with callback

I use hundreds of times A and URL and a little less LOAD

For none of these functions or helpers have I found a direct replacement in 
py4web.

LOAD does not exist in py4web, A does not have the possibility of ajax 
calls with the callback parameter and URL is totally different in py4web.

It would be great to see some of this web2py magic carried over to py4web.

El domingo, 6 de febrero de 2022 a las 15:37:49 UTC+1, vinid...@gmail.com 
escribió:

> Have you managed to make a welcome template based on Unpoly?
>
> On Wednesday, March 4, 2020 at 8:37:51 PM UTC+7 yamand...@gmail.com wrote:
>
>> Sorry for the typo.
>> I want to make a welcome template based on unpoly soon.
>>
>> Em sex., 28 de fev. de 2020 às 04:21, AGRogers  
>> escreveu:
>>
>>> https://unpoly.com/  
>>>
>>> On Fri, 28 Feb 2020 at 16:22, Massimo Di Pierro  
>>> wrote:
>>>
 never heard of unpolly.js and cannot find it. Have a link?


 On Wednesday, 26 February 2020 19:32:20 UTC-8, Carlos Costa wrote:
>
> LOAD is a very cool thing! And beginners just say WOW when they can 
> create ajax-like experience so easy.
> But, IMO, it lacks some important features for modern apps, like error 
> handling and history handling.
>
> I have written some simple functions to help cover these things...
>
> Another way I found very useful was to use unpolly.js. It's magic but 
> makes me a little lazyer about getting things done with vue.js.
> (BTW they created unpolly to avoid using things like vue, react, etc, 
> really!)
>
> I would like very much to use vue.js but I am still noob regarding how 
> to use it with py4web.
> Maybe we should really encourage vue.js and stuff alike... but an 
> initial pattern would be cool.
> And IMO it should be simple and very cleared stated in the docs.
> So no one will miss LOAD.
>
> Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:
>>
>> HI,
>>
>> I am beginning to experiment with py4web, I like the sound of it and 
>> I am looking to convert a web2py project to py4web to see how they 
>> compare.
>>
>> It appears that the LOAD (helper?) that was available in web2py 
>> templates is not available in py4web. I was using this to populate part 
>> of 
>> a web page, I liked the way you had the option to use LOAD to call a 
>> separate URL (within the same app) and insert the result into your page 
>> before returning the page to the client.
>>
>> What is the reason for the absence of LOAD in py4web? is there a 
>> recommended alternative method of achieving the same effect? I have used 
>> a 
>> mixture of ajax=True and ajax=False options for this feature.
>>
>> Thanks,
>>
>> Richard.
>>
> -- 
 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.
 To view this discussion on the web visit 
 https://groups.google.com/d/msgid/web2py/22d8b9cf-9ce2-464b-809e-32d4dd84fd02%40googlegroups.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.
>>>
>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/web2py/CACWMBMPXoWfp9iZ7yQtbCw_YU6yh-9M2_xAQ%3Dzj4ocyWTzxuXw%40mail.gmail.com
>>>  
>>> 
>>> .
>>>
>>
>>
>> -- 
>> At.
>>
>> Carlos J. Costa
>> --
>> Cientista da Computação - Esp. Gestão em Telecom
>>
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- 

Re: [web2py] Re: LOAD in py4web

2022-02-06 Thread Alexei Vinidiktov
Have you managed to make a welcome template based on Unpoly?

On Wednesday, March 4, 2020 at 8:37:51 PM UTC+7 yamand...@gmail.com wrote:

> Sorry for the typo.
> I want to make a welcome template based on unpoly soon.
>
> Em sex., 28 de fev. de 2020 às 04:21, AGRogers  
> escreveu:
>
>> https://unpoly.com/  
>>
>> On Fri, 28 Feb 2020 at 16:22, Massimo Di Pierro  
>> wrote:
>>
>>> never heard of unpolly.js and cannot find it. Have a link?
>>>
>>>
>>> On Wednesday, 26 February 2020 19:32:20 UTC-8, Carlos Costa wrote:

 LOAD is a very cool thing! And beginners just say WOW when they can 
 create ajax-like experience so easy.
 But, IMO, it lacks some important features for modern apps, like error 
 handling and history handling.

 I have written some simple functions to help cover these things...

 Another way I found very useful was to use unpolly.js. It's magic but 
 makes me a little lazyer about getting things done with vue.js.
 (BTW they created unpolly to avoid using things like vue, react, etc, 
 really!)

 I would like very much to use vue.js but I am still noob regarding how 
 to use it with py4web.
 Maybe we should really encourage vue.js and stuff alike... but an 
 initial pattern would be cool.
 And IMO it should be simple and very cleared stated in the docs.
 So no one will miss LOAD.

 Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:
>
> HI,
>
> I am beginning to experiment with py4web, I like the sound of it and I 
> am looking to convert a web2py project to py4web to see how they compare.
>
> It appears that the LOAD (helper?) that was available in web2py 
> templates is not available in py4web. I was using this to populate part 
> of 
> a web page, I liked the way you had the option to use LOAD to call a 
> separate URL (within the same app) and insert the result into your page 
> before returning the page to the client.
>
> What is the reason for the absence of LOAD in py4web? is there a 
> recommended alternative method of achieving the same effect? I have used 
> a 
> mixture of ajax=True and ajax=False options for this feature.
>
> Thanks,
>
> Richard.
>
 -- 
>>> 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.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/web2py/22d8b9cf-9ce2-464b-809e-32d4dd84fd02%40googlegroups.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.
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/web2py/CACWMBMPXoWfp9iZ7yQtbCw_YU6yh-9M2_xAQ%3Dzj4ocyWTzxuXw%40mail.gmail.com
>>  
>> 
>> .
>>
>
>
> -- 
> At.
>
> Carlos J. Costa
> --
> Cientista da Computação - Esp. Gestão em Telecom
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/a94a7f90-df6a-4f3f-bb04-05bc44e86509n%40googlegroups.com.


Re: [web2py] Re: LOAD in py4web

2020-03-04 Thread Carlos Costa
Sorry for the typo.
I want to make a welcome template based on unpoly soon.

Em sex., 28 de fev. de 2020 às 04:21, AGRogers 
escreveu:

> https://unpoly.com/
>
> On Fri, 28 Feb 2020 at 16:22, Massimo Di Pierro <
> massimo.dipie...@gmail.com> wrote:
>
>> never heard of unpolly.js and cannot find it. Have a link?
>>
>>
>> On Wednesday, 26 February 2020 19:32:20 UTC-8, Carlos Costa wrote:
>>>
>>> LOAD is a very cool thing! And beginners just say WOW when they can
>>> create ajax-like experience so easy.
>>> But, IMO, it lacks some important features for modern apps, like error
>>> handling and history handling.
>>>
>>> I have written some simple functions to help cover these things...
>>>
>>> Another way I found very useful was to use unpolly.js. It's magic but
>>> makes me a little lazyer about getting things done with vue.js.
>>> (BTW they created unpolly to avoid using things like vue, react, etc,
>>> really!)
>>>
>>> I would like very much to use vue.js but I am still noob regarding how
>>> to use it with py4web.
>>> Maybe we should really encourage vue.js and stuff alike... but an
>>> initial pattern would be cool.
>>> And IMO it should be simple and very cleared stated in the docs.
>>> So no one will miss LOAD.
>>>
>>> Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:

 HI,

 I am beginning to experiment with py4web, I like the sound of it and I
 am looking to convert a web2py project to py4web to see how they compare.

 It appears that the LOAD (helper?) that was available in web2py
 templates is not available in py4web. I was using this to populate part of
 a web page, I liked the way you had the option to use LOAD to call a
 separate URL (within the same app) and insert the result into your page
 before returning the page to the client.

 What is the reason for the absence of LOAD in py4web? is there a
 recommended alternative method of achieving the same effect? I have used a
 mixture of ajax=True and ajax=False options for this feature.

 Thanks,

 Richard.

>>> --
>> 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+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/web2py/22d8b9cf-9ce2-464b-809e-32d4dd84fd02%40googlegroups.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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/CACWMBMPXoWfp9iZ7yQtbCw_YU6yh-9M2_xAQ%3Dzj4ocyWTzxuXw%40mail.gmail.com
> 
> .
>


-- 
At.

Carlos J. Costa
--
Cientista da Computação - Esp. Gestão em Telecom

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CAGsD4NxWHPktoJ9fAJg_f9YKKg7GhpCDg7sRmj_DGHnq2bqC3A%40mail.gmail.com.


Re: [web2py] Re: LOAD in py4web

2020-02-27 Thread AGRogers
https://unpoly.com/

On Fri, 28 Feb 2020 at 16:22, Massimo Di Pierro 
wrote:

> never heard of unpolly.js and cannot find it. Have a link?
>
>
> On Wednesday, 26 February 2020 19:32:20 UTC-8, Carlos Costa wrote:
>>
>> LOAD is a very cool thing! And beginners just say WOW when they can
>> create ajax-like experience so easy.
>> But, IMO, it lacks some important features for modern apps, like error
>> handling and history handling.
>>
>> I have written some simple functions to help cover these things...
>>
>> Another way I found very useful was to use unpolly.js. It's magic but
>> makes me a little lazyer about getting things done with vue.js.
>> (BTW they created unpolly to avoid using things like vue, react, etc,
>> really!)
>>
>> I would like very much to use vue.js but I am still noob regarding how to
>> use it with py4web.
>> Maybe we should really encourage vue.js and stuff alike... but an initial
>> pattern would be cool.
>> And IMO it should be simple and very cleared stated in the docs.
>> So no one will miss LOAD.
>>
>> Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:
>>>
>>> HI,
>>>
>>> I am beginning to experiment with py4web, I like the sound of it and I
>>> am looking to convert a web2py project to py4web to see how they compare.
>>>
>>> It appears that the LOAD (helper?) that was available in web2py
>>> templates is not available in py4web. I was using this to populate part of
>>> a web page, I liked the way you had the option to use LOAD to call a
>>> separate URL (within the same app) and insert the result into your page
>>> before returning the page to the client.
>>>
>>> What is the reason for the absence of LOAD in py4web? is there a
>>> recommended alternative method of achieving the same effect? I have used a
>>> mixture of ajax=True and ajax=False options for this feature.
>>>
>>> Thanks,
>>>
>>> Richard.
>>>
>> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/22d8b9cf-9ce2-464b-809e-32d4dd84fd02%40googlegroups.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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CACWMBMPXoWfp9iZ7yQtbCw_YU6yh-9M2_xAQ%3Dzj4ocyWTzxuXw%40mail.gmail.com.


[web2py] Re: LOAD in py4web

2020-02-27 Thread Massimo Di Pierro
never heard of unpolly.js and cannot find it. Have a link?


On Wednesday, 26 February 2020 19:32:20 UTC-8, Carlos Costa wrote:
>
> LOAD is a very cool thing! And beginners just say WOW when they can create 
> ajax-like experience so easy.
> But, IMO, it lacks some important features for modern apps, like error 
> handling and history handling.
>
> I have written some simple functions to help cover these things...
>
> Another way I found very useful was to use unpolly.js. It's magic but 
> makes me a little lazyer about getting things done with vue.js.
> (BTW they created unpolly to avoid using things like vue, react, etc, 
> really!)
>
> I would like very much to use vue.js but I am still noob regarding how to 
> use it with py4web.
> Maybe we should really encourage vue.js and stuff alike... but an initial 
> pattern would be cool.
> And IMO it should be simple and very cleared stated in the docs.
> So no one will miss LOAD.
>
> Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:
>>
>> HI,
>>
>> I am beginning to experiment with py4web, I like the sound of it and I am 
>> looking to convert a web2py project to py4web to see how they compare.
>>
>> It appears that the LOAD (helper?) that was available in web2py templates 
>> is not available in py4web. I was using this to populate part of a web 
>> page, I liked the way you had the option to use LOAD to call a separate URL 
>> (within the same app) and insert the result into your page before returning 
>> the page to the client.
>>
>> What is the reason for the absence of LOAD in py4web? is there a 
>> recommended alternative method of achieving the same effect? I have used a 
>> mixture of ajax=True and ajax=False options for this feature.
>>
>> Thanks,
>>
>> Richard.
>>
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/22d8b9cf-9ce2-464b-809e-32d4dd84fd02%40googlegroups.com.


[web2py] Re: LOAD in py4web

2020-02-26 Thread Carlos Costa
LOAD is a very cool thing! And beginners just say WOW when they can create 
ajax-like experience so easy.
But, IMO, it lacks some important features for modern apps, like error 
handling and history handling.

I have written some simple functions to help cover these things...

Another way I found very useful was to use unpolly.js. It's magic but makes 
me a little lazyer about getting things done with vue.js.
(BTW they created unpolly to avoid using things like vue, react, etc, 
really!)

I would like very much to use vue.js but I am still noob regarding how to 
use it with py4web.
Maybe we should really encourage vue.js and stuff alike... but an initial 
pattern would be cool.
And IMO it should be simple and very cleared stated in the docs.
So no one will miss LOAD.

Em domingo, 23 de fevereiro de 2020 15:18:51 UTC-3, RHC escreveu:
>
> HI,
>
> I am beginning to experiment with py4web, I like the sound of it and I am 
> looking to convert a web2py project to py4web to see how they compare.
>
> It appears that the LOAD (helper?) that was available in web2py templates 
> is not available in py4web. I was using this to populate part of a web 
> page, I liked the way you had the option to use LOAD to call a separate URL 
> (within the same app) and insert the result into your page before returning 
> the page to the client.
>
> What is the reason for the absence of LOAD in py4web? is there a 
> recommended alternative method of achieving the same effect? I have used a 
> mixture of ajax=True and ajax=False options for this feature.
>
> Thanks,
>
> Richard.
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/89450727-f077-4ce0-9046-29b39bfc8a90%40googlegroups.com.


[web2py] Re: LOAD in py4web

2020-02-26 Thread Dave S


On Tuesday, February 25, 2020 at 1:14:41 PM UTC-8, RHC wrote:
>
> Just to confirm, will that call to foo(0 return the html generated using 
> that function and it's template?
>
> My view on the various follow up questions about LOAD is that we should 
> use existing frameworks where possible rather than complicating py4web. The 
> appeal of py4web is that it has less of it's own javascript which in web2py 
> was awkward to work around if it didn't work the way you needed it to.
>
>

My take is that one of the selling points of web2py was "everything you 
need to get going"  (aka "everything is in the box"),
and I think both FORM and LOAD are key parts of that.  I think Massimo has 
thought quite a bit about modularity, so I'd expect that FORM (and any 
putative LOAD) would be easy to swap out.

That said, the pjax suggestion and the alpine suggestion are both 
intriguing to someone with minimal VUE/REACT/ANGULAR experience.


Dave
/dps


On Monday, February 24, 2020 at 12:02:01 AM UTC, Val K wrote:
>>
>> for server side you can
>> @action("foo")
>> @action.uses("foo.html")
>> def foo():
>> return dict(...)
>>
>> @action("bar")
>> @action.uses("bar.html")
>> def bar():
>> return dict(foo_content = foo())
>>
>> # bar.html
>> [[=XML(foo_content)]]
>>
>>
>> for the client side, I suppose, you have to do it by yourself using pure 
>> js or some lib (JQuery, axios, Vue.js ... )
>>
>>
>>
>> On Sunday, February 23, 2020 at 9:18:51 PM UTC+3, RHC wrote:
>>>
>>> HI,
>>>
>>> I am beginning to experiment with py4web, I like the sound of it and I 
>>> am looking to convert a web2py project to py4web to see how they compare.
>>>
>>> It appears that the LOAD (helper?) that was available in web2py 
>>> templates is not available in py4web. I was using this to populate part of 
>>> a web page, I liked the way you had the option to use LOAD to call a 
>>> separate URL (within the same app) and insert the result into your page 
>>> before returning the page to the client.
>>>
>>> What is the reason for the absence of LOAD in py4web? is there a 
>>> recommended alternative method of achieving the same effect? I have used a 
>>> mixture of ajax=True and ajax=False options for this feature.
>>>
>>> Thanks,
>>>
>>> Richard.
>>>
>>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/e3548b97-47e1-474e-b332-f138a39dfa6a%40googlegroups.com.


[web2py] Re: LOAD in py4web

2020-02-25 Thread RHC
Just to confirm, will that call to foo(0 return the html generated using 
that function and it's template?

My view on the various follow up questions about LOAD is that we should use 
existing frameworks where possible rather than complicating py4web. The 
appeal of py4web is that it has less of it's own javascript which in web2py 
was awkward to work around if it didn't work the way you needed it to.

On Monday, February 24, 2020 at 12:02:01 AM UTC, Val K wrote:
>
> for server side you can
> @action("foo")
> @action.uses("foo.html")
> def foo():
> return dict(...)
>
> @action("bar")
> @action.uses("bar.html")
> def bar():
> return dict(foo_content = foo())
>
> # bar.html
> [[=XML(foo_content)]]
>
>
> for the client side, I suppose, you have to do it by yourself using pure 
> js or some lib (JQuery, axios, Vue.js ... )
>
>
>
> On Sunday, February 23, 2020 at 9:18:51 PM UTC+3, RHC wrote:
>>
>> HI,
>>
>> I am beginning to experiment with py4web, I like the sound of it and I am 
>> looking to convert a web2py project to py4web to see how they compare.
>>
>> It appears that the LOAD (helper?) that was available in web2py templates 
>> is not available in py4web. I was using this to populate part of a web 
>> page, I liked the way you had the option to use LOAD to call a separate URL 
>> (within the same app) and insert the result into your page before returning 
>> the page to the client.
>>
>> What is the reason for the absence of LOAD in py4web? is there a 
>> recommended alternative method of achieving the same effect? I have used a 
>> mixture of ajax=True and ajax=False options for this feature.
>>
>> Thanks,
>>
>> Richard.
>>
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/8ffd5a19-8ad7-4d88-971b-91d1c07b0231%40googlegroups.com.


Re: [web2py] Re: LOAD in py4web

2020-02-25 Thread Christian Varas
I think it can be usefull if you use another template not based in vue.

Cheers.

El El lun, 24 de feb. de 2020 a la(s) 03:31, Massimo Di Pierro <
massimo.dipie...@gmail.com> escribió:

> We can add it in utils. But before we do. Do other peopl find it useful?
> Is that a pattern we should encourage vs, for example, vue.js?
>
> On Sunday, 23 February 2020 10:18:51 UTC-8, RHC wrote:
>>
>> HI,
>>
>> I am beginning to experiment with py4web, I like the sound of it and I am
>> looking to convert a web2py project to py4web to see how they compare.
>>
>> It appears that the LOAD (helper?) that was available in web2py templates
>> is not available in py4web. I was using this to populate part of a web
>> page, I liked the way you had the option to use LOAD to call a separate URL
>> (within the same app) and insert the result into your page before returning
>> the page to the client.
>>
>> What is the reason for the absence of LOAD in py4web? is there a
>> recommended alternative method of achieving the same effect? I have used a
>> mixture of ajax=True and ajax=False options for this feature.
>>
>> Thanks,
>>
>> Richard.
>>
>
>> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/7cfaf6be-8be3-41dc-8745-ab59716f68af%40googlegroups.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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CA%2Bs%2BuJsTJwf1sw%3D-oR4MyZqVhyDcjkn-xYaQA-fbHyBAXyb%2Bqw%40mail.gmail.com.


Re: [web2py] Re: LOAD in py4web

2020-02-24 Thread António Ramos
I think LOAD should be gone and we should move this kind of interaction to
the client part.
Also py4web should stick with server stuff and let client stuff integrate
better an in a more independent way.
For me FORM / smartgrid should also be gone. Vuetify and buefy tables are
awesome. dont try to compete with that because your are competing with the
power of vuejs. Just ease the connection between the 2.
The problem i see with vuejs is working with vue components. Without the
need for vue components maybe a simpler tool like
https://github.com/alpinejs/alpine  should be enough



Regards
António




Em seg., 24 de fev. de 2020 às 06:31, Massimo Di Pierro <
massimo.dipie...@gmail.com> escreveu:

> We can add it in utils. But before we do. Do other peopl find it useful?
> Is that a pattern we should encourage vs, for example, vue.js?
>
> On Sunday, 23 February 2020 10:18:51 UTC-8, RHC wrote:
>>
>> HI,
>>
>> I am beginning to experiment with py4web, I like the sound of it and I am
>> looking to convert a web2py project to py4web to see how they compare.
>>
>> It appears that the LOAD (helper?) that was available in web2py templates
>> is not available in py4web. I was using this to populate part of a web
>> page, I liked the way you had the option to use LOAD to call a separate URL
>> (within the same app) and insert the result into your page before returning
>> the page to the client.
>>
>> What is the reason for the absence of LOAD in py4web? is there a
>> recommended alternative method of achieving the same effect? I have used a
>> mixture of ajax=True and ajax=False options for this feature.
>>
>> Thanks,
>>
>> Richard.
>>
> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/7cfaf6be-8be3-41dc-8745-ab59716f68af%40googlegroups.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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CAEM0BxO6k7M-Yfk-r3Oc2B2zvScvxSQ%2BLC%3DXPtXWttSGnO0irA%40mail.gmail.com.


[web2py] Re: LOAD in py4web

2020-02-23 Thread Massimo Di Pierro
We can add it in utils. But before we do. Do other peopl find it useful? Is 
that a pattern we should encourage vs, for example, vue.js?

On Sunday, 23 February 2020 10:18:51 UTC-8, RHC wrote:
>
> HI,
>
> I am beginning to experiment with py4web, I like the sound of it and I am 
> looking to convert a web2py project to py4web to see how they compare.
>
> It appears that the LOAD (helper?) that was available in web2py templates 
> is not available in py4web. I was using this to populate part of a web 
> page, I liked the way you had the option to use LOAD to call a separate URL 
> (within the same app) and insert the result into your page before returning 
> the page to the client.
>
> What is the reason for the absence of LOAD in py4web? is there a 
> recommended alternative method of achieving the same effect? I have used a 
> mixture of ajax=True and ajax=False options for this feature.
>
> Thanks,
>
> Richard.
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/7cfaf6be-8be3-41dc-8745-ab59716f68af%40googlegroups.com.


Re: [web2py] Re: LOAD in py4web

2020-02-23 Thread Carlos Cesar Caballero
Or maybe using something like https://github.com/MoOx/pjax

El dom., 23 de febrero de 2020 7:02 p. m., Val K 
escribió:

> for server side you can
> @action("foo")
> @action.uses("foo.html")
> def foo():
> return dict(...)
>
> @action("bar")
> @action.uses("bar.html")
> def bar():
> return dict(foo_content = foo())
>
> # bar.html
> [[=XML(foo_content)]]
>
>
> for the client side, I suppose, you have to do it by yourself using pure
> js or some lib (JQuery, axios, Vue.js ... )
>
>
>
> On Sunday, February 23, 2020 at 9:18:51 PM UTC+3, RHC wrote:
>>
>> HI,
>>
>> I am beginning to experiment with py4web, I like the sound of it and I am
>> looking to convert a web2py project to py4web to see how they compare.
>>
>> It appears that the LOAD (helper?) that was available in web2py templates
>> is not available in py4web. I was using this to populate part of a web
>> page, I liked the way you had the option to use LOAD to call a separate URL
>> (within the same app) and insert the result into your page before returning
>> the page to the client.
>>
>> What is the reason for the absence of LOAD in py4web? is there a
>> recommended alternative method of achieving the same effect? I have used a
>> mixture of ajax=True and ajax=False options for this feature.
>>
>> Thanks,
>>
>> Richard.
>>
> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/47d4dc6b-caa6-439a-bd1f-4913af352d63%40googlegroups.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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CAKHqNp4%3DyOj-ZRLD0W7z0wZMS%2BTqtmXHEzVNQ-Nnukcg4CsW4A%40mail.gmail.com.


[web2py] Re: LOAD in py4web

2020-02-23 Thread Val K
for server side you can
@action("foo")
@action.uses("foo.html")
def foo():
return dict(...)

@action("bar")
@action.uses("bar.html")
def bar():
return dict(foo_content = foo())

# bar.html
[[=XML(foo_content)]]


for the client side, I suppose, you have to do it by yourself using pure js 
or some lib (JQuery, axios, Vue.js ... )



On Sunday, February 23, 2020 at 9:18:51 PM UTC+3, RHC wrote:
>
> HI,
>
> I am beginning to experiment with py4web, I like the sound of it and I am 
> looking to convert a web2py project to py4web to see how they compare.
>
> It appears that the LOAD (helper?) that was available in web2py templates 
> is not available in py4web. I was using this to populate part of a web 
> page, I liked the way you had the option to use LOAD to call a separate URL 
> (within the same app) and insert the result into your page before returning 
> the page to the client.
>
> What is the reason for the absence of LOAD in py4web? is there a 
> recommended alternative method of achieving the same effect? I have used a 
> mixture of ajax=True and ajax=False options for this feature.
>
> Thanks,
>
> Richard.
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/47d4dc6b-caa6-439a-bd1f-4913af352d63%40googlegroups.com.