[英]How to have a button with CSS and Javascript classes in a layout
Is it possible to have button in layout which is HTML and have CSS style and some Java-script classes. 是否可以在HTML布局中具有CSS样式和一些Javascript类的按钮。
For example : 例如 :
this button comes with some CSS and some Js. 此按钮带有一些CSS和一些Js。 So how is possible to have CSS and Js with HTML content in a layout?
那么,如何在布局中使CSS和Js带有HTML内容呢?
Thanks.. 谢谢..
You have to use the WebView in your layout http://developer.android.com/reference/android/webkit/WebView.html 您必须在布局中使用WebView http://developer.android.com/reference/android/webkit/WebView.html
String summary = "<html><body>Your html content.</body></html>";
webview.loadData(summary, "text/html", null);
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.