简体   繁体   中英

Opening a shadowbox.js popup window using a hash

What I'd like to do is put an anchor tag on an element that will direct to a different website of mine, and I'd like to designate a hash so that a shadowbox.js popup window will open up all in one click.

The link would look something like this:

<a href="mysecondwebsite.html#popup"><img src="hellostackoverflow.png"></a>

and clicking on that link would open up "mysecondwebsite.html" and open the shadowbox.js pop up on that page.

It sounds easy enough, but I'm not sure if it's possible.. any help is greatly appreciated

在新页面上页面加载时运行的代码只需查看window.location.hash并激活其值指示的任何弹出窗口(激活弹出窗口之前,您可能还必须将窗口滚动回到顶部)。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM