Question

I want to implement a JQuery mobile expandable list or an accordion in my road safety app that houses numerous motorcycling and car tips. I was told that I could import the html from file:///mnt/sdcard/AppInventor/assets/test.html using the WebViewer component but I am currently clueless.
My questions are:

  1. How do I go about the accordion code using JQuery mobile?
  2. How do I use the WebViewer component to load the accordion screen?

Thanks in advance!

Edit: I managed to get the jQuery Mobile Docs source code snippets. Any further information on it's implementation would be more than appreciated though!

Edit 2: I know the file paths to the screens as this works in development file:///mnt/sdcard/AppInventor/assets/test.html because App Inventor puts the file in an assets folder when it loads

and this works from the apk file:///android_asset/test.html

How do I bundle this html page with the assets?

Was it helpful?

Solution

You can find loads of App Inventor examples using HTML/JavaScript here

If you need to access your html page with input parameters, you will have to download the html file from somewhere to your sd card because of an Android bug, else you can upload it to the assets of your project.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top