$(document).ready(function() { alert("location: " + document.location + ", state: " + JSON.stringify(event.state)); });