I am trying to display HTML content in a web view. The UI is simple jQuery Mobile. The HTML displays, but the CSS and JavaScript from the assets folder.
Css and js file will resides in assets folder.
Note : Put you .css and .js file in assets folder as well
here is the implementation code
OUTPUT :
You may like Web View with Progress Dialog visit
Css and js file will resides in assets folder.
Note : Put you .css and .js file in assets folder as well
here is the implementation code
OUTPUT :
WebView wvSpecification= (WebView)rootview.findViewById(R.id.wvSpecification);
StringBuilder
sb = new StringBuilder();
sb.append("<HTML
xmlns='http://www.w3.org/1999/xhtml'>" +
"<HEAD>"+
"<meta
name='viewport' content='width=device-width, initial-scale=1'>"+
"<link
rel='stylesheet' href=cssfilename.css'/>"+
"<link
rel='stylesheet' href= cssfilename.css'/>"+
"<script
src= jsfilename.js' type='text/javascript'></script>"+
"</HEAD>");
sb.append("<body>"+
"<h1>Mobile</h1>"+
"<table
class='responsive'>"+
"<tr>"+
"<th>Company
Name</th>"+
"<th>Model
Name</th>"+
"<th>Version</th>"+
"</tr>"+
"<tr>"+
"<td>Google</td>"+
"<td>Nexus
5</td>"+
"<td>4.4</td>"+
"</tr>"+
"<tr>"+
"<td>HTC</td>"+
"<td>Desire
X</td>"+
"<td>4.1</td>"+
"</tr>"+
"<tr>"+
"<td>Samsung</td>"+
"<td>Galaxy
s4</td>"+
"<td>4.3</td>"+
"</tr>"+
"</table>"+
"</body>");
sb.append("</HTML>");
wvSpecification.loadDataWithBaseURL("file:///android_asset/",sb.toString(),"text/html","UTF-8",null);
I will be happy if you will provide your feedback or follow this blog. Any suggestion and help will be appreciated.
Thank you :)
ReplyDeleteThis is an awesome post.Really very informative and creative contents. These concept is a good way to enhance the knowledge.I like it and help me to development very well.Thank you for this brief explanation and very nice information.Well, got a good knowledge.
angularjs Training in bangalore
angularjs Training in electronic-city
angularjs Training in online
angularjs Training in marathahalli
I'm here representing the visitors and readers of your own website say many thanks for many remarkable
ReplyDeletepython training Course in chennai | python training in Bangalore | Python training institute in kalyan nagar
It is better to engaged ourselves in activities we like. I liked the post. Thanks for sharing.
ReplyDeleteJava training in Annanagar | Java training in Chennai
Java training in Chennai | Java training in Electronic city
Very good brief and this post helped me alot. Say thank you I searching for your facts. Thanks for sharing with us!
ReplyDeleteData Science Course in Indira nagar | Data Science Course in Electronic city
Python course in Kalyan nagar | Data Science course in Indira nagar
Data Science Course in Marathahalli | Data Science Course in BTM Layout
I was looking for this certain information for a long time. Thank you and good luck.
ReplyDeleteMicrosoft Azure online training
Selenium online training
Java online training
Python online training
uipath online training
This comment has been removed by the author.
ReplyDeletevery interesting article and good information
ReplyDeleteAngularJS Training in Chennai | AngularJS Training in Anna Nagar | AngularJS Training in OMR | AngularJS Training in Porur | AngularJS Training in Tambaram | AngularJS Training in Velachery
This article is very much helpful and i hope this will be an useful information for the needed one. Keep on updating these kinds of informative things... c Software Testing Training in Chennai | Software Testing Training in Anna Nagar | Software Testing Training in OMR | Software Testing Training in Porur | Software Testing Training in Tambaram | Software Testing Training in Velachery
ReplyDeleteThanks for any other wonderful post. Where else may just anyone get that type of info in such a perfect means of writing? I’ve a presentation next week, and I am on the look for such information.
ReplyDeleteangular js training in chennai
angular js training in velachery
full stack training in chennai
full stack training in velachery
php training in chennai
php training in velachery
photoshop training in chennai
photoshop training in velachery
Amazing article. Your blog helped me to improve myself in many ways thanks for sharing this kind of wonderful informative blogs in live. I have bookmarked more article from this website. Such a nice blog you are providing ! Kindly Visit Us
ReplyDeleteangular js training in chennai
angular js training in tambaram
full stack training in chennai
full stack training in tambaram
php training in chennai
php training in tambaram
photoshop training in chennai
photoshop training in tambaram
I simply unearthed your site and needed to say that I have truly appreciated perusing your blog entries. I want to say thanks for great sharing.
ReplyDeletedata science training in chennai
data science training in annanagar
android training in chennai
android training in annanagar
devops training in chennai
devops training in annanagar
artificial intelligence training in chennai
artificial intelligence training in annanagar
I am relatively certain I will learn a lot of new stuff right here! Good luck for the following!
ReplyDeletedata science training in chennai
data science training in annanagar
android training in chennai
android training in annanagar
devops training in chennai
devops training in annanagar
artificial intelligence training in chennai
artificial intelligence training in annanagar
Wonderful concept! These was very helpful for enhance my knowledge. I am reading your post regularly, it's very interesting. Please posting.
ReplyDeleteAngular js Training in Chenai
Angular js Training in Velachery
Angular js Training in Tambaram
Angular js Training in Porur
Angular js Training in Omr
Angular js Training in Annanagar
Fascinating Post. Really helpful and informative. Thanks for sharing
ReplyDeleteSelenium Training in Chennai
Selenium Training in Velachery
Selenium Training in Tambaram
Selenium Training in Porur
Selenium Training in Omr
Selenium Training in Annanagar
very interesting article and good information
ReplyDeleteJava course in chennai
python course in chennai
web designing and development course in chennai
selenium course in chennai
digital-marketing seo course in chennai
A very nice guide. I will definitely follow these tips. Thank you for sharing such detailed article. I am learning a lot from you. amazon web services aws training in chennai
ReplyDeletemicrosoft azure training in chennai
workday training in chennai
android-training-in chennai
ios training in chennai
I simply unearthed your site and needed to say that I have truly appreciated perusing your blog entries. I want to say thanks for great sharing.
ReplyDeleteIELTS Coaching in chennai
German Classes in Chennai
GRE Coaching Classes in Chennai
TOEFL Coaching in Chennai
Spoken english classes in chennai | Communication training