var filename = url.split('/').pop();
var filename = location.pathname.substr(location.pathname.lastIndexOf("/")+1);