this load works in 2.5.1 (please take a look at web2py.app.test251.w2p).
;-)
the web2py.js is available on the page, because it is imported in test(),
and the trigger was able to call this js.
Am Montag, 14. Oktober 2013 16:43:38 UTC+2 schrieb Niphlod:
>
> wait a sec. before (< 2.6.0) the js to "trigger" the load was inlined, but
> web2py.js HAD to be available nonetheless to make that happen. What's
> changed is that now web2py.js takes also care of the "trigger".
>
> def test2()
> ret = DIV(XML("test2 <br>"))
> ret.append(LOAD(f='test3', ajax=True))
> return ret
>
> def test3():
> return DIV('test 3')
>
>
> Opening test2 as it is and hoping that it loads test3 doesn't work in >
> 2.6.0 AND doesn't work in < 2.6.0 , because neither test2 nor test3 load
> web2py.js.
>
> Il giorno lunedì 14 ottobre 2013 15:43:21 UTC+2, Michael Helbling ha
> scritto:
>>
>>
>> Yes, but there was no need to load the js two times on the same page <
>> 2.6. Even if there was an ajax call between the initially page load and the
>> LOAD.
>> if you import the web2py.app.test251.w2p into w2p 2.5.1, you will see,
>> this behavior worked before the upgrade. And there are a lot of these Loads
>> in 7 different applications.
>>
>> Do you mean something like this?
>> def test2():
>> ret = DIV(XML("test2 <br>"))
>> ret.append(XML("<script src='/test272/static/js/jquery.js'
>> type='text/javascript'></script>"))
>> ret.append(XML("<script src='/test272/static/js/web2py.js'
>> type='text/javascript'></script>"))
>> ret.append(LOAD(f='test3', ajax=True))
>> return ret
>>
>> *This works :/ but this will cause a lot of work to find and expand every
>> ajax call which has a LOAD in it.
>>
>> If you have an idea, how to solve this properly in an other way, please
>> let me know.
>> Else, thanks a lot for your support and patience! It's good to know the
>> reason, even if I can not solve it immediately :D
>>
>>
>>
>> Am Montag, 14. Oktober 2013 14:54:36 UTC+2 schrieb Niphlod:
>>>
>>> You aren't using any view if you return raw HTML tags (as in return
>>> DIV('...'))
>>>
>>> Il giorno lunedì 14 ottobre 2013 14:38:02 UTC+2, Michael Helbling ha
>>> scritto:
>>>>
>>>>
>>>>
>>>> hmm, in the view test.html is the layout included, in the layout the
>>>> web2py_ajax.html and there are the js included.? :S
>>>> do you mean the web2py_ajax.html?
>>>>
>>>> i tried to copy the app to w2p 2.5.1 too, but it seems there were some
>>>> changes, that needs more changes to migrate an app to a lower version :/
>>>> sorry, i didn't test this direction before..
>>>>
>>>>
>>>> if i create a new simple app in w2p 2.5.1, insert the code for the test
>>>> functions and views. It works. I attached the app from 2.5.1
>>>> (web2py.app.test251)
>>>>
>>>> then i packed the app and installed it in w2p 2.7.2. After this, i
>>>> copied the web2py.js, jquery.js and appadmin controller/view as in the
>>>> changelog described. But the load still doesn't work. I attached this app
>>>> too (web2py.app.test272.w2p)
>>>> are there more files that needs an update? *i'm not sure which template
>>>> you mean
>>>>
>>>>
>>>>
>>>>
>>>> Am Montag, 14. Oktober 2013 13:55:05 UTC+2 schrieb Niphlod:
>>>>>
>>>>> of course it doesn't..... but it won't work even with pre-2.6.0
>>>>> releases ..... you aren't including the template which holds the js to
>>>>> load
>>>>> the component! :D
>>>>>
>>>>> Il giorno lunedì 14 ottobre 2013 08:13:36 UTC+2, Michael Helbling ha
>>>>> scritto:
>>>>>>
>>>>>>
>>>>>> Dear Niphlod
>>>>>>
>>>>>> Attached is a minimal App. In w2p 2.7.2 i just created a new simple
>>>>>> application and inserted the test code, I posted last time. The load of
>>>>>> "test3" doesn't work and in the div is just "loading..."
>>>>>>
>>>>>> I tried it on 2 different pcs (at home and work) in firefox and
>>>>>> chrome, so the client shouldn't be the problem. Can you reproduce the
>>>>>> problem with the attached app? the whole code is original, except the 3
>>>>>> test functions in the default controller and the view default/test.html
>>>>>>
>>>>>>
>>>>>>
>>>>>> Am Freitag, 11. Oktober 2013 22:15:22 UTC+2 schrieb José L.:
>>>>>>>
>>>>>>>
>>>>>>> El 11/10/2013 21:52, "Niphlod" <[email protected]> escribió:
>>>>>>> >
>>>>>>> > talking about minimal app, heh.... anyway, better than nothing.
>>>>>>>
>>>>>>> I know, but I am answering from my phone, without a PC available ;)
>>>>>>>
>>>>>>> > taken movuca, setupped, doesn't work (as advertised in web2py's
>>>>>>> changelog).
>>>>>>> > Take web2py.js from welcome and overwrite web2py.js in
>>>>>>> /static/bootstrap/js/web2py.js
>>>>>>> > Next issue, movuca ships jquery 1.7.1 (november 2011).
>>>>>>> > web2py.js requires something jquery having $.parseHTML ... update
>>>>>>> jquery too and you'll only receive a problem about
>>>>>>> bootstrap-transition.js,
>>>>>>> that is trying to do something with the (now unsupported) $.browser.
>>>>>>> > Update bootstrap-transition.js and movuca works like a charm.
>>>>>>> >
>>>>>>>
>>>>>>> I will check it again, maybe I made some mistake copying those
>>>>>>> files, but I knew this has to be done.
>>>>>>>
>>>>>>> Thanks
>>>>>>>
>>>>>>> > tl;dr : movuca just needs a few upgrades to work.
>>>>>>> >
>>>>>>> >
>>>>>>> > On Friday, October 11, 2013 9:19:01 PM UTC+2, José L. wrote:
>>>>>>> >>
>>>>>>> >> Movuca app from Bruno, available at Github has this behaviour.
>>>>>>> >>
>>>>>>> >> El 11/10/2013 21:05, "Niphlod" <[email protected]> escribió:
>>>>>>> >>>
>>>>>>> >>> can you pack a minimal app to reproduce the behaviour please ? I
>>>>>>> can't reproduce the issue you're seeing
>>>>>>> >>>
>>>>>>> >>> On Friday, October 11, 2013 8:55:19 AM UTC+2, Michael Helbling
>>>>>>> wrote:
>>>>>>> >>>>
>>>>>>> >>>>
>>>>>>> >>>> yes, jquery.js and web2py.js are configured in web2py_ajax.html
>>>>>>> and jquery.js is preceding web2py.js:
>>>>>>> >>>> {{
>>>>>>> >>>> response.files.insert(0,URL('static','js/jquery.js'))
>>>>>>> >>>> response.files.insert(1,URL('static','css/calendar.css'))
>>>>>>> >>>> response.files.insert(2,URL('static','js/calendar.js'))
>>>>>>> >>>> response.files.insert(3,URL('static','js/web2py.js'))
>>>>>>> >>>> response.files.insert(4,URL('static','js/jquery.blockUI.js'))
>>>>>>> >>>> response.include_meta()
>>>>>>> >>>> response.include_files()
>>>>>>> >>>> }}
>>>>>>> >>>>
>>>>>>> >>>>
>>>>>>> >>>> The workaround from José works. After replacing the
>>>>>>> compileapp.py through the old one, every load is working again. I'll
>>>>>>> take a
>>>>>>> closer look at the file in the afternoon.
>>>>>>> >>>>
>>>>>>> >>>>
>>>>>>> >>>> Am Donnerstag, 10. Oktober 2013 21:15:40 UTC+2 schrieb Niphlod:
>>>>>>> >>>>>
>>>>>>> >>>>> is jquery.js preceding web2py.js in your layout.html ?
>>>>>>> >>>>>
>>>>>>> >>>>> On Thursday, October 10, 2013 8:27:04 AM UTC+2, Michael
>>>>>>> Helbling wrote:
>>>>>>> >>>>>>
>>>>>>> >>>>>>
>>>>>>> >>>>>> Yes, i already copied the web2py.js, appadmin controller and
>>>>>>> views from the latest welcome app to all my apps.
>>>>>>> >>>>>> Without copying the web2py.js, no load worked. But even with
>>>>>>> the latest web2py.js, not all loads are working. that's my problem and
>>>>>>> i
>>>>>>> don't know why some load doesn't work. In version 2.5.1 with the old
>>>>>>> web2py.js all loads worked and in version 2.7.1 with the new web2py.js
>>>>>>> ~30%
>>>>>>> of the loads in our app don't work anymore.
>>>>>>> >>>>>>
>>>>>>> >>>>>> as described, i don't know what to try anymore. May you can
>>>>>>> give me a hint what i could try additionally?
>>>>>>> >>>>>>
>>>>>>> >>>>>>
>>>>>>> >>>>>> Am Mittwoch, 9. Oktober 2013 18:53:02 UTC+2 schrieb Massimo
>>>>>>> Di Pierro:
>>>>>>> >>>>>>>
>>>>>>> >>>>>>> You need to copy web2py.js from the latest welcome app into
>>>>>>> your old app.
>>>>>>> >>>>>>>
>>>>>>> >>>>>>
>>>>>>> >>>>>> On Wednesday, 9 October 2013 04:57:20 UTC-5, Michael Helbling
>>>>>>> wrote:
>>>>>>> >>>>>>>
>>>>>>> >>>>>>> First of all to avoid this question: Yes I copied the
>>>>>>> appadmin and javascript file from the welcome app to my own app ;-)
>>>>>>> >>>>>>>
>>>>>>> >>>>>>
>>>>>>> >>>>>>
>>>>>>> >>>
>>>>>>> >>> --
>>>>>>> >>> 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 [email protected].
>>>>>>> >>>
>>>>>>> >>> For more options, visit https://groups.google.com/groups/opt_out
>>>>>>> .
>>>>>>> >
>>>>>>> > --
>>>>>>> > 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 [email protected].
>>>>>>> > For more options, visit https://groups.google.com/groups/opt_out.
>>>>>>>
>>>>>>
--
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.