location

window.location.href = window.location.pathname + search;

原文地址:https://www.cnblogs.com/jason-beijing/p/10327435.html