标签: javascript jquery twitter-bootstrap
如果网址的delete带有HASH参数,如何在页面加载后打开id引导模式?
delete
HASH
id
示例:
http://example.com/properties#delete-86
答案 0 :(得分:2)
你可以在你的剧本开头做:
// You can retrieve the id in 'matches' variable if needed if (matches = window.location.href.match(/#delete-([0-9])+/)) { $('#my-modal').modal('show'); }