I had this error

jqm.mobile.autoInitializePage = ;

on page load.
I think I followed coorectly the installation instructions
I attach the libraries directory and also the jquery mobile config

Comments

adamjanzen’s picture

StatusFileSize
new4.23 KB

Seems the settings array is not set. Have written patch that accounts for this when outputting the js.

adamjanzen’s picture

Status: Active » Needs review
minoroffense’s picture

Status: Needs review » Needs work

Change the isset's to array_key_exists

http://php.net/manual/en/function.array-key-exists.php

adamjanzen’s picture

Status: Needs work » Needs review
StatusFileSize
new4.39 KB

Sorry, replaced isset with array_key_exists. Updated patch attached.

egarias’s picture

This patch is working, the error is gone.
But I don't see a jquery theme as in the previous version.
my site is http://peoplenews.me and my mobile site is http://m.peoplenews.me

jasonsavino’s picture

StatusFileSize
new4.23 KB

patch failed.
changed: if (isSet($settings['ajaxEnabled'])
to: if (isSet($settings['ajaxEnabled']))

updated patch attached

jasonsavino’s picture

Status: Needs review » Reviewed & tested by the community

patch applied to dev branch. works for me.

egarias’s picture

Applied the patch same result for me, still doesn't show mobile theme.

i don't see any javascript mobile, this script in my head may help

<!--//--><![CDATA[//><!--
var jqm = jQuery.noConflict();
jqm(document).bind("mobileinit", function() {
});
//--><!]]> 

The dev branch has not the patch in

jasonsavino’s picture

make sure you visit the configuration page: /admin/config/jquerymobile/settings

egarias’s picture

On global options:
if using "Other jQuery Mobile File Location" the help text is incorrect "Enter the location where the jquery files are hosted (no trailing slashes)."

I tried to download the frameworks as told in the docs and install in sites/all/libraries, This gave me confusion, at the end after your recomendation I checked all the options and the only working for me was "Framework location Hosted (http://code.jquery.com)" as i was using in the previous version.
With this config the mobile theme is showing on my site.

In admin/config/jquerymobile/settings/peoplenews_mobile (being peoplenews_mobile) my subtheme, I am not able to set it up.
I have these errors

The value minScrollBack must be a number.
The value of subPageUrlKey must not be null.
The value of activePageClass must not be null.
The value of activeBtnClass must not be null.
The value of loadingMessage must not be null.
The value of pageLoadErrorMessage must not be null.

Because they come empty, I tried to fill them:

minScrollBack: 150
subPageUrlKey: 1
activePageClass; activepageclass
activeBtnClass: activebtnclass
loadingMessage: Loading
pageLoadErrorMessage: Loading error

With those values, the submit form is ok, but they are not being saved

Thanks

minoroffense’s picture

@egarias I think your issue is actually this one #1561288: Undefined index errors when loading theme settings on admin page

I'm applying the patch from #6.

minoroffense’s picture

Actually scratch that, #6 should be using array_key_exists since isset would return false on some values like '' which may be valid values in the jQuery Mobile settings.

If the array key exists in the settings array, we output the value.

minoroffense’s picture

Assigned: Unassigned » minoroffense
Status: Reviewed & tested by the community » Needs review
Alexander Matveev’s picture

kscheirer’s picture

Assigned: minoroffense » Unassigned
Status: Needs review » Fixed

Patch has already been applied, this has been fixed in latest dev. So has the related issue #1787786: Settings form does not save anything. In any case, there's no patch to review here.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.