Comments (6)
  • Add a Comment
  • Edit
  • More Actions v
  • Quarantine this Entry

1 rdv224 commented Permalink

Does this work on worklight 5.0.6. I followed the instructions. It created a projects but did not have the jquery libraries installed.
The project was created correctly. But under common it had a folder, jqueryMobile (no version number). In this folder was only the images, no css or js files. Also the generated html file had no reference to any jquery library.

I have file
Is this a bug in 5.0.6 ?

2 DavidDhuyvetter commented Permalink

There is something odd about I've seen exactly the same behavior. I don't see that behavior with

If you expand onto the file system and load jQuery Mobile from that folder rather than from the archive when you create the Worklight project, everything imports correctly.
I have no idea whether this is a Worklight Studio problem, or some subtle problem with how the jQuery Mobile 1.3.1 zip file was created. Development is aware of this issue.

3 arif_iq commented Permalink

I just has have been noted the same behavior in 5.0.6 with jqm 1.3.1, have to copy files manually into worklight environment, hope to get the solution soon.

4 rdv224 commented Permalink

Code initialised twice. Using jquery 1.3.1 caused initOptions to be unvokde twice. This in turn causes other
java script files to be run twice.

Below is the projects main html (ESRIDemo7.html). Each time initOtions is loaded, FSMapDataCollection and
JsonStoreController are also reloaded.
<!--application UI goes here-->
<script src="js/initOptions.js"></script>
<script src="js/ESRIDemo7.js"></script>
<script src="js/messages.js"></script>
<script src="js/FSMapDataCollection.js"></script>
<script src="js/JsonStoreController.js"></script>
JsonStoreController has severl stmts like this:
$("#UpdateData").on("click", this.updateDatabase.bind(this));
These stmts get run twice. Which causes the function updateDatabase to be
executed twice.
This stmt caused the problem:
<script src="jqueryMobile/"></script>
I removed it and exverything in initialized once. The program doesn't work
but the at least its initalized only once.
Using Worklight 5.0.6.
Does JQuery 1.9 work ?

5 rdv224 commented Permalink

Also tried the min library
<script src="jqueryMobile/"></script>

same results. initOptions.js invked twice.

6 rdv224 commented Permalink

Updated Worklight to This fixed the problem for any new project created. Rebuilding a project created under 5.0.6 did NOT fix the problem.