Note that there are some explanatory texts on larger screens.

plurals
  1. POjQuery FancyBox stopping ASP.NET Logout link from working
    text
    copied!<p>I am using the FancyBox jQuery plugin (http://fancybox.net/) in my ASP.NET website and have hit a small but annoying issue.</p> <p>The site uses the default ASP.NET login controls and then displays some links which pop open a form in a FancyBox - all this works great. If I <em>do not</em> click any of the FancyBox links and then hit the logout link (provided by the LoginStatus control) again everything works as it should.</p> <p>However if I click on one of the FancyBox links and then close it the logout link no longer works, nothing happens at all - it would appear as if the postback is not firing for some reason.</p> <p>I have done some searching but not come across anyone with a similar issue - has anyone seen this issue before? </p> <p>Thanks in advance</p> <p>UPDATE: With a little help from IE debugger I have tracked the problem down to a JavaScript error here -</p> <pre><code>function __doPostBack(eventTarget, eventArgument) { if (!theForm.onsubmit || (theForm.onsubmit() != false)) { theForm.__EVENTTARGET.value = eventTarget; theForm.__EVENTARGUMENT.value = eventArgument; theForm.submit(); } </code></pre> <p>More specifically on the line that sets the eventtarget and the error I recieve is -</p> <blockquote> <p>SCRIPT5007: Unable to set value of the property 'value': object is null or undefined</p> </blockquote> <p>UPDATE 2: I have put a temporary fix in place - basically I just hook into the onClosed event and reload the page at that point -</p> <pre><code>$("#form_popup").fancybox({ 'scrolling': 'no', 'titleShow': true, 'onClosed' : function() { location.reload(); } }); </code></pre> <p>Of course the problem is the page will be fully reloaded from scratch missing the point of using jQuery but at least it works! </p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload