你想实现什么效果
location.href路径后面带参数,通过判断参数处理显示和隐藏。类似这种,点击跳转时候拼接参数,跳转后获取参数:https://blog.csdn.net/F_mengze/article/details/107317470?