Last active
December 13, 2015 23:59
-
-
Save mhawksey/4995998 to your computer and use it in GitHub Desktop.
Enter this on your index.html just before end <body> tag
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
$(document).ready(function() { | |
var hash = window.location.hash.replace(/^[#\/]*/, ''); | |
var request = hash.split('/', 2); | |
var type = request[0]; | |
var term = request[1]; | |
if (type === "search"){ | |
$(".search-query").val(term); | |
$(".navbar-search").submit(); | |
} | |
}); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment