Fixed submit error

This commit is contained in:
Kasper Rynning-Tønnesen
2016-04-25 20:51:07 +02:00
parent d6a8887c76
commit a2de4bf7df
4 changed files with 4 additions and 6 deletions

View File

@@ -30,9 +30,7 @@
Loading... Loading...
</li> </li>
<li class="search-container hide" id="search-wrapper"> <li class="search-container hide" id="search-wrapper">
<form id="song_search_form">
<input id="search" class="search_input" type="text" title="Search for songs..." placeholder="Find song on YouTube..." onsubmit="null;" autocomplete="off" /> <input id="search" class="search_input" type="text" title="Search for songs..." placeholder="Find song on YouTube..." onsubmit="null;" autocomplete="off" />
</form>
</li> </li>
</ul> </ul>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -180,7 +180,6 @@ function init(){
if(event.keyCode == 13){ if(event.keyCode == 13){
Search.search(search_input); Search.search(search_input);
}else{ }else{
timeout_search = setTimeout(function(){ timeout_search = setTimeout(function(){
Search.search(search_input); Search.search(search_input);
}, 1000); }, 1000);
@@ -357,7 +356,8 @@ $(document).on("click", ".suggested-link", function(e){
$("#suggestions").css("display", "block"); $("#suggestions").css("display", "block");
}); });
$(document).on("submit", "#chatForm", function(){ $(document).on("submit", "#chatForm", function(e){
e.preventDefault();
Chat.chat(document.getElementById("chatForm").input); Chat.chat(document.getElementById("chatForm").input);
}); });