On 24/04/2013 10:02 AM, Rowdy wrote:
Greetings,
I am developing a desktop/mobile application using web2py 2.4.6
(currently hosted on CentOS 6.4 with Python 2.6.6, web2py running from
source).
If I have an SQLFORM containing a date field, when I tap on the field on
a mobile device the popup calendar does not appear. Currently tested on
iOS using Safari and Chrome, and on Android using Chrome, but this also
happens when using a desktop version of Firefox with a user agent
switcher and masquerading as a mobile device.
If I simply reload the page (without doing anything else) and then tap
on the date field again, the popup calendar appears.
A similar page in the desktop version also contains a date field, and
the popup calendar appears first time and every time the field is
clicked without needing to reload the page.
Anyone got any ideas why this is happening?
I was wondering whether something was being cached, which prevented the
page initialisation script from running, at least not until the page is
reloaded, but that is grasping at straws.
Looking at the page source (on the desktop Firefox masquerading as a
mobile browser, where the same behaviour is exhibited), the before and
after reload page source is identical.
Any insight appreciated.
Thank you in advance.
Rowdy
This still seems to be a problem with 2.4.7.
Controller:
from gluon.contrib.user_agent_parser import mobilize
@mobilize
def cal():
form = FORM(
TABLE(
TR('Date', INPUT(_name = 'date1', _id = 'date1', _type =
'text', _class = 'date', requires = IS_DATE())),
TR('', INPUT(_type = 'submit', _value = 'Refresh'))
)
)
return dict(form = form)
View:
{{extend 'cal/layout.html'}}
{{=form}}
views/cal/layout.html copied from admin/views/plugin_jqmobile and
static/plugin_jqmobile directory also copied from admin.
The same problem is exhibited with SQLFORM().
Any suggestions welcome, thanks.
Rowdy
--
---
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.
For more options, visit https://groups.google.com/groups/opt_out.