Allow your visitors to play YouTube videos on your site, bringing them closer to you in a way that's uncommon on most websites.
Live Lessons Example - ASP.NET VB - play YouTube videos on your page
[Part 1]: Create a New webpage named "Youtube.aspx". Create a Form with a text field and a Submit button. Set the form's method to [POST] and the action to the same page we are on.
[Part 2]: Using an [IF STATEMENT] lets us keep the content on the same page and display it only when the visitor provides a YouTube video ID. Example: C-FGs18RCwk And the Submit Button has been fired, with the Value of [Play YouTube Video]
Update: I failed at providing the correct information in this script. I provided Classic ASP, instead of VB.NET.
<%' Create our variable
dim getSub asstring = request.form("Submit")
dim UTube asstring = ""
' Next, we call our variable and query it against the value of the input
if getSub = "Play YouTube Video" then
UTube = trim(request.form("YouTube"))
UTube = replace(UTube, "'","'")
%>
[Part 3]: The YouTube Object Properties. The Video will display here. You can change the width and height to the following values.
width="560" height="315"
width="640" height="360"
width="853" height="480"
width="1280" height="720"
Going higher than this can make some visitors' pages too large for their monitors.