Issue
I use webview to display youtube content. For some reason, it adds a frame to the video.
Does anyone knows how to remove it?
My code is:
String data_html = "<iframe width=\"300\" height=\"162\" src=\"http://www.youtube.com/embed
/RbyBj-pmNwM\" frameborder=\"0\"></iframe>";
video.loadData(data_html, "text/html", null);
And here is an example of the white frame I can't get rid of:
Solution
The solution was to use a fully constructed html page:
String data_html = "<!DOCTYPE HTML> <html xmlns=\"http://www.w3.org/1999/xhtml\" xmlns:og=\"http://opengraphprotocol.org/schema/\" xmlns:fb=\"http://www.facebook.com/2008/fbml\"> <head></head> <body style=\"margin:0 0 0 0; padding:0 0 0 0;\"> <iframe width=\"300\" height=\"162\" src=\"http://www.youtube.com/embed/RbyBj-pmNwM\" frameborder=\"0\"></iframe> </body> </html> ";
Answered By - Asaf Pinhassi
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.