获取hash值页面跳转

js部分

//获取hash值
var $staff_id = window.location.hash;
//提取字符串
var $staff_flag = $staff_id.substr(1, 5);
if ($staff_id.length && ($staff_flag == "staff")) {
//选择对象
$staff_id = $staff_id.replace('#','.');
var $this = $staff_id ;

//coding here 

}