I see you want a different window, not a modal.
then you have to put the form logic in its own controller action and call
it from js
<button onclick="window.open("{{=URL('form_action)}}");">click me</button>
On Wednesday, 10 February 2016 18:00:44 UTC-6, [email protected]
wrote:
>
> Thank you for the answer Massimo. I did this like you said to put the form
> in the body in index/popup.html however, it didn't pop up like the example
> in the link above. Instead I got it in the same browser. I am guessing my
> implementation is wrong.
>
> <div class="modal fade">
> <div class="modal-dialog">
> <div class="modal-content">
> <div class="modal-header">
> <button type="button" class="close" data-dismiss="modal"
> aria-hidden="true">×</button>
> <h4 class="modal-title">Modal title</h4>
> </div>
> <div class="modal-body">
>
> {{=form}}
>
> </div>
> <div class="modal-footer">
> <button type="button" class="btn btn-default"
> data-dismiss="modal">Close</button>
> <button type="button" class="btn btn-primary">Save changes</button>
> </div>
> </div><!-- /.modal-content -->
> </div><!-- /.modal-dialog -->
> </div><!-- /.modal -->
>
>
>
>
> On Wednesday, February 10, 2016 at 5:06:28 PM UTC-5, Massimo Di Pierro
> wrote:
>>
>> Bootstrap3 has built-int modals:
>> https://nakupanda.github.io/bootstrap3-dialog/
>> You can but {{=form}} in the body of the modal.
>>
>> On Tuesday, 9 February 2016 14:26:05 UTC-6, [email protected] wrote:
>>>
>>> Hello, A new user migrating from Django to web2py and absolutely loving
>>> it. A quick question. How do I use a light box or a pop up window to
>>> display a form in my view?
>>>
>>>
>>> for example in default/index.html
>>>
>>> {{=form}}
>>>
>>> Want to show that form in a pop up window.
>>>
>>
--
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/d/optout.