diff --git a/index.php b/index.php
index 135fed1a..9de4f303 100755
--- a/index.php
+++ b/index.php
@@ -25,7 +25,7 @@
/
-
+
-
Loading...
@@ -64,7 +64,7 @@
-
+
diff --git a/static/js/search.js b/static/js/search.js
index 99561bac..e1fff902 100755
--- a/static/js/search.js
+++ b/static/js/search.js
@@ -19,7 +19,8 @@ $(document).ready(function()
$(".search_input").focus();
$(".search_input").keyup(function(event) {
- var search_input = $(this).val();
+ search_input = $(this).val();
+ console.log(search_input);
if(event.keyCode == 13 && search_input == "fireplace")
{
if(!peis)
@@ -114,16 +115,22 @@ $(document).keyup(function(e) {
function showSearch(){
$("#search-wrapper").toggleClass("hide");
+ if(window.mobilecheck())
+ {
+ $(".search-container").toggleClass("hide");
+ $(".search_input").focus();
+ }
$("#song-title").toggleClass("hide");
+ $("#second-song-title").toggleClass("hide");
$("#search").focus();
}
function search(search_input){
- $("#results").html('');
- if(search_input !== ""){
- var keyword= encodeURIComponent(search_input);
+ $(".search_results").html('');
+ if(window.search_input !== ""){
+ var keyword= encodeURIComponent(window.search_input);
//response= http://nixo.no/txt/?4574f9b9dd286e0d#X+kzTvyFv5IrdkGQtqmoquhekDRCPJX9N24PSn86CFE=
//var yt_url = "https://www.googleapis.com/youtube/v3/search?videoEmbeddable=true&part=snippet&q=thefatrat&fields=items(id%2Csnippet)&type=video&videoDuration=medium&videoCategoryId=15&key=AIzaSyC3hq93zqwdwcjO8HyD9oToLLFotoAjyWo";
diff --git a/static/js/youtube.js b/static/js/youtube.js
index e00a3729..91d4490a 100755
--- a/static/js/youtube.js
+++ b/static/js/youtube.js
@@ -75,6 +75,8 @@ socket.on(chan.toLowerCase()+",np", function(obj)
if(ytplayer.getDuration() > seekTo)
ytplayer.seekTo(seekTo);
}
+ else
+ getTitle(song_title, viewers);
}
});
@@ -209,13 +211,15 @@ function getTitle(titt, v)
{
var outPutWord = v > 1 ? "viewers" : "viewer";
var title= decodeURIComponent(titt);
- var elem = document.getElementById('song-title');
+ if(!window.mobilecheck())
+ var elem = document.getElementById('song-title');
+ else
+ var elem = document.getElementById('second-song-title');
document.title = title + " • Zöff";
- if(!window.mobilecheck()){
elem.innerHTML = title;
document.getElementById('viewers').innerHTML = v + " " + outPutWord;
elem.title = title + " • " + v + " " + outPutWord;
- }
+
}
function errorHandler(newState)