Marek123 Marek123 - 1 year ago 142
Javascript Question

Bootstrap - direct link to modal window

Is it possible to have an url like this:

www.url.com/#imprint


(or similar) to link directly to the page with the opened modal window?

is this possible? Any hints?

Thank you!

Answer Source

You might be able to do something like this.

if (window.location.hash == "#imprint") {
     $('#myModal').modal('show');
}
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download