Liberty BASIC Community Forum
« HTML5 GENERATOR- Plays MP4 videos »

Welcome Guest. Please Login or Register.
Nov 22nd, 2017, 01:31am


Rules|Home|Help|Search|Recent Posts|Notification


« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: HTML5 GENERATOR- Plays MP4 videos  (Read 378 times)
michael
Guest
xx HTML5 GENERATOR- Plays MP4 videos
« Thread started on: May 29th, 2015, 12:33am »

I will try to make a GOOGLE version later CUS it works with HTML5
Make sure you type FILENAME.MP4 or it wont play (filename is just an example)

If your computer says it has blocked the content because of Active X controls ... You probably don't want to allow it to play the video.
If all else fails with internet explorer.. right click the Myvideo.html file and select GOOGLE to open it
GOOGLE WORKS !!

I was able to do it once on Internet explorer and it wouldn't allow it again. And on my Windows 8 computer it wouldn't allow it at all.. I played a home made video.

READ THE INSTRUCTIONS: You will need to put a MP4 video in the same directory as this HTML file is generated.
If you do not have D:\ directory then you will need to change to a writeable directory that you do have..
( I have marked where you will need to make the changes)
And this program has been tested on a windows 7 computer which would have a directory named F:\
*** ALSO- make sure the mp4 video is one you made
Code:
print "This program requires a HTML5 compatible browser (most are compatible now)"
print "Type the full name of the video that you put with the HTML file we are using"
print "Just the filename and extension: eg myvideo.mp4 (make sure its a MP4 video)"
print " "
print "The HTML file will be  D:\Myvideo.html"
print " "
print "You do not have to put the path to the file as long as it has been copied to"
print " where the HTML file will be."
Input Name$
file$="D:\Myvideo.html" ''<<<<<<<<<<<<<  If you dont have D:\ directory rename to a writable location
open file$ for output as #1
#1 "<!DOCTYPE html>"
#1 "<html lang="+chr$(34)+"en"+chr$(34)+">"
#1 "<head>"
#1 "<meta charset="+chr$(34)+"UTF-8"+chr$(34)+">"
#1 "<title>VIDEO PLAYER</title>"
#1 "</head>"
#1 "  <body>"
#1 "  <video controls autoplay>"
#1 "  <source src="+chr$(34)+Name$+chr$(34)+" type="+chr$(34)+"video/mp4"+chr$(34)+">"
#1 "  Video element not supported by your browser."
#1 " </video>"
#1 "  </body>"
#1 "  </html>"
close #1
navigator$ ="C:\Program Files (x86)\Internet Explorer\iexplore.exe"
db$ = navigator$+" "+"D:\Myvideo.html" '<<<<<<<<<<<<<  If you dont have D:\ directory rename to a writable location
run db$  ' to actually launch this ( enable this line to see what it does
end
 

« Last Edit: May 29th, 2015, 01:31am by michael » User IP Logged

Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

Rules|Home|Help|Search|Recent Posts|Notification

Donate $6.99 for 50,000 Ad-Free Pageviews!

| |

This forum powered for FREE by Conforums ©
Sign up for your own Free Message Board today!
Terms of Service | Privacy Policy | Conforums Support | Parental Controls