Question

I am trying to put in a log-in form via a lightbox using inline content, however, I would like to have this gracefully degrade if the user does not have javascript. According to the fancybox documentation, my anchor tag should have a href of the ID of the content to display, like so:

<a href="#fancybox-logon">Log On</a>
<div id="fancybox-logon" style="display:none;">My log on form!</div>

This is fine, until someone visits with JavaScript off. Then they're linked to something that doesn't exist. A better solution, in my mind, is markup like this:

<a href="logon.php" data-lightbox="fancybox-logon">Log on!</a>
<div id="fancybox-logon" style="display:none;">My log on form!</div>

This way, if something breaks down, the user will be directed to an external log on page. Is there a way to achieve this with either fancybox or some other lightbox solution?

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top