• Resolved Andrew Leonard

    (@andrewleonard)


    There is a problem with your code and `Simple Lightbox’ plugin Version 2.8.1, By Archetyped
    I have discussed this with them and they think it is your problem
    I have a solution for it but it means ediiting your code every time you have an update
    This is the code I add:

    Add the following code into The Event Calendar's obj.onPopState handler
    wp-content/plugins/the-events-calendar/src/resources/js/views/manager.js
    starting line 372
    
    	    /* START add this code AL 20210203 */
    	    var stateViewer = event.originalEvent.state.viewer;
    	    if ( stateViewer == "slb_default") {
    			return false;
    		}
    	    /* END add this code AL 20210203 */

    It would be nice for me if you could sort this out

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi there!

    Can you tell me what your problem was that this code is fixing?

    Thanks!

    Thread Starter Andrew Leonard

    (@andrewleonard)

    I have the EC “Events List” widgets in my primary sidebar.
    This used to go “screwy” after I clicked on an image that openned up with the lightbox effect.
    The lightbox plugin is “Simple Lightbox” Version 2.8.1 by Archetyped
    I asked them and they said it was your code that was causing the problem
    My very clever friend said that I needed to add the code above to the obj.onPopState handler
    I don’t know but I think this code has been amended by EC now to prevent this happenning
    My fix is not in your code and the problem no longer exist
    If you wanted to see it I would have to goback to a previous version of TEC
    If you tell me what code to remove from the obj.onPopState handler, I would oblige

    That won’t be necessary. I’m glad the issue is no longer present, apologies for the delayed response.

    Have a great week!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘obj.onPopState handler’ is closed to new replies.