Skip to content

Commit

Permalink
corrected jquery version
Browse files Browse the repository at this point in the history
  • Loading branch information
pavan71198 committed Jan 30, 2018
1 parent 71bcaf4 commit be6d643
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 13 deletions.
4 changes: 0 additions & 4 deletions jquery-3.2.1.slim.min.js

This file was deleted.

2 changes: 2 additions & 0 deletions jquery.min.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions popup.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" type="text/css" href="css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="css/style.css">
<script src="jquery.min.js" type="text/javascript"></script>
<script src="bootstrap.min.js" type="text/javascript"></script>
<script src="popup.js" type="text/javascript"></script>
</head>
<body>
<div id="not-logged-in" class="d-none container">
Expand Down Expand Up @@ -46,7 +49,4 @@
</div>
<br><br><br>
</div>
<script src="jquery-3.2.1.slim.min.js"></script>
<script src="bootstrap.min.js"></script>
<script src="popup.js" type="text/javascript"></script>
</body>
12 changes: 6 additions & 6 deletions popup.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,23 +29,23 @@ $(document).ready(function(){
$('#youtube').removeClass('d-none');
var videoid = tabURL.searchParams.get("v");
console.log(videoid);
$('#upload-button').onclick(function(){
var videoname = $('#video-name').value();
$('#upload-button').on('click',function(){
var videoname = $('#video-name').val();
$.ajax({
url: "http://localhost:8000/uploadvideo",
url: "http://localhost:8000/uploadvideo/",
type: "POST",
data: {
videoname: videoname,
source: "youtube",
source: 'youtube',
videoid: videoid,
csrfmiddlewaretoken: csrftoken
},
success: function () {
$('#upload-success').removeClass("d-none");
$('#upload-form').addClass("d-none");
console.log("Upload request successfull");
console.log("Upload request successful");
},
error:function(){
error: function(){
console.log("Upload error");
}
});
Expand Down

0 comments on commit be6d643

Please sign in to comment.