1: <%@ Page Language="C#" AutoEventWireup="true" CodeFile="GetYouTubeVedios.aspx.cs"
2: Inherits="Youtube_GetYouTubeVedios" %>
3:
4: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5: <html xmlns="http://www.w3.org/1999/xhtml">
6: <head runat="server">
7: <title>Get Youtube Vedios</title>
8: </head>
9: <script src="swfobject.js" type="text/jscript"></script>
10: <script type="text/javascript">
11:
12: var params = { allowScriptAccess: "always" };
13: var atts = { id: "myytplayer" };
14:
15:
16: </script>
17: <body>
18: <form id="form1" runat="server">
19: <div>
20: <table >
21: <tr>
22: <td>
23: Sample application to fetch vedios from Youtube.
24: </td>
25: </tr>
26: <tr>
27: <td>
28: First you need to create developer account in youtube to get developer key. You can get
29: <a href="http://youtube.com/signup?next=/my_profile_dev" target="_blank">here</a>.
30: </td>
31: </tr>
32: <tr>
33: <td>
34: Enter Seach text :
35: <asp:TextBox ID="txtSearch" runat="server" ></asp:TextBox>
36: <asp:Button ID="btnSearch" runat="server" Text="Search" OnClick="btnSearch_Click" />
37: </td>
38: </tr>
39: <tr>
40: <td>
41: <br />
42: </td>
43: </tr>
44: <tr>
45: <td width="80%">
46: <asp:DataList ID="dlYoutube" runat="server" CellPadding="4" ForeColor="#333333" OnItemDataBound="dlYoutube_ItemDataBound">
47: <ItemTemplate>
48: <table>
49: <tr>
50: <td colspan="2">
51: <asp:Label ID="lblTotle" Font-Bold="true" runat="server" Text='<%# Eval("title")%>'></asp:Label>
52: </td>
53: </tr>
54: <tr>
55: <td valign="top">
56: <%--<a id="aURL" style="text-decoration: none" runat="server" href='<%# Eval("url")%>'>
57: <asp:Image ID="imgImage" runat="server" ImageUrl='<%# Eval("thumbnail_url")%>' />
58: </a>--%>
59: <div runat="server" id="player"></div>
60: <asp:Literal ID="ltrl" runat="server"></asp:Literal>
61: </td>
62: <td valign="top">
63: <table width="100%">
64: <tr>
65: <td>
66: <asp:Label ID="lblAuthor" runat="server" Text="Author : "></asp:Label>
67: </td>
68: <td>
69: <asp:Label ID="lblAuthorName" runat="server" Text='<%# Eval("author")%>'></asp:Label>
70: </td>
71: </tr>
72: <tr>
73: <td valign="top">
74: <asp:Label ID="Label1" runat="server" Text="Description : "></asp:Label>
75: </td>
76: <td>
77: <asp:Label ID="Label2" runat="server" Text='<%# Eval("description")%>'></asp:Label>
78: </td>
79: </tr>
80: <tr>
81: <td>
82: <asp:Label ID="Label3" runat="server" Text="Rating : "></asp:Label>
83: </td>
84: <td>
85: <asp:Label ID="Label4" runat="server" Text='<%# Eval("rating_avg")%>'></asp:Label>
86: </td>
87: </tr>
88: </table>
89: </td>
90: </tr>
91: </table>
92: </ItemTemplate>
93: <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
94: <SelectedItemStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
95: <AlternatingItemStyle BackColor="White" ForeColor="#284775" />
96: <ItemStyle BackColor="#F7F6F3" ForeColor="#333333" />
97: <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
98: </asp:DataList>
99: </td>
100: </tr>
101: </table>
102: </div>
103: </form>
104: </body>
105: </html>