Help! Not loading HTML file to WebViewer

hello, everyone.

I am trying to open a HTML file on the WebViewer but when i use the IA companion i get "Webpage not available"

i did a research on the internet and i found couple different methods that have solved the issue for other people.

i used:

file:///mnt/sdcard/Makeroid/assets/index2.html

file:///mnt/sdcard/Appinventor/assets/index2.html

file:///android_asset/index2.html

and none off them seems to work for me. i also try using the ActivityStarter with no success. I change my html url path to http://www.google.com and it work fine with WebViewer & ActivityStarter.

i upload the html file as a text file with the name index ( the original html file name is index2.html, i upload it as index.txt just for uploading purposes.)

What am I doing wrong?

thanks!

index.txt (13.9 KB)

Assuming your html file is uploaded to assets (Media) use this:

http://localhost/index2.html

This will work in development and compiled versions of your app.

Your next issue will be that the form is posting to register.php. Firstly, is this in the same directory as index2.html (e.g. assets - Media). Secondly, this will not work because AI2 does not run an http server (php server). Your post file needs to be on a php server on the internet somewhere. you will need to edit your index2.html to reflect this.

<form action="register.php" method="POST">

Thank you @TIMAI2, i was in need of just showing the form on the app. the HTML form runs perfects at it is I am using XAMPP control panel to run MySQL for the database.

Thanks for the help!

Maybe ill keep playing with it and follow your input to see where i get...

You could always just run everything off the server, and call your registration page from the internet:

https://<yourdomain>/index2.html

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.