Youtube V3 API JavaScript

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"             "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">  <html xmlns="http://www.w3.org/1999/xhtml"        xmlns:ui="http://xmlns.jcp.org/jsf/facelets">  <head>    <title><ui:insert name="title">Default title</ui:insert></title>    <script src="https://code.jquery.com/jquery-2.1.3.min.js"></script>    <script src="https://apis.google.com/js/client.js?onload=init"></script>    <script>       videoIdArray = new Array(10);   function youtube() {    //init();       document.getElementById("search").value;    alert("Clicked");   var indexx = 0;     alert("Clicked");         e.preventDefault();         // prepare the request         var request = gapi.client.youtube.search.list({              part: "snippet",              type: "video",               q: encodeURIComponent($("#search").val()).replace(/%20/g, "+"),              maxResults: 5,              order: "viewCount",              publishedAfter: "2015-01-01T00:00:00Z"         });         alert("Clicked");    }  function init() {      gapi.client.setApiKey("AIzaSy...");      gapi.client.load("youtube", "v3", function() {             });  }         </script>      </head>    <body>  <ui:debug hotkey="x" rendered="#{initParam['javax.faces.FACELETS_DEVELOPMENT']}"/>    <div id="header">      <ui:insert name="header">        Header area.  See comments below this line in the source.       <!--  include your header file or uncomment the include below and create header.xhtml in this directory -->       <!-- <ui:include src="header.xhtml"/> -->      </ui:insert>  </div>      <div id="content">        <form action="#">            <input type="text" id="search" name="search" value="Submit"></input>        <input type="submit" value="Submit"></input>    </form>      </div>    <div id="footer">    <ui:insert name="footer">       Footer area.  See comments below this line in the source.       <!--  include your header file or uncomment the include below and create footer.xhtml in this directory -->       <!--<ui:include src="footer.xhtml"/>  -->    </ui:insert>  </div>    </body>    </html>

I want to make a videos website using Java Server Pages. i want to read youtube data. and save video title and videoId in mysql database using JSP. please guied me to share with me any documents related to this work. i have run a code in browser but i am confused in this code. i want to assign video Id to JSP Variable and then save it into database.

Replay

Category: javascript Time: 2016-07-30 Views: 0

Related post

iOS development

Android development

Python development

JAVA development

Development language

PHP development

Ruby development

search

Front-end development

Database

development tools

Open Platform

Javascript development

.NET development

cloud computing

server

Copyright (C) avrocks.com, All Rights Reserved.

processed in 0.156 (s). 12 q(s)