Forum Replies Created

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter criticnic

    (@criticnic)

    Hi time-space,
    I never was able to figure it out with Collapse-o-matic. I ended up just using the jQuery Accordion function, adding the code into my theme’s header. Quite a workaround but it works for we wanted to do ??

    Hi mikesakoon,

    We have run into the same issue with displaying a video using the plugin and having the audio still playing in the background when closing the pop-up, and fortunately were able to come up with a solution! Not sure if you are still in need of help on this, but hopefully it will help someone having a similar issue. The solution involves editing the plugin file (displet-pop.php), so use caution when doing this!
    1) in your displet pop widget, give your YouTube iframe tag a class name. So your code in your widget should look something like this:
    <iframe class="yt" src="https://videourl.com" width="600" height="448"></iframe>
    2) in displet-pop.php, find the function called hideDispletPop(). after the last line of code before the closing } in that function, add a new jQuery line that looks something like the following:

    function hideDispletPop() {
    	jQuery('#displetpop').hide();
    	jQuery('body').removeClass('displetpop');
    	jQuery(".yt").attr('src',''); /* new line here */
    }

    What that last line does is clears the ‘src’ attribute of your iframe. This basically says when you close the pop-up, set the iframe to nothing so there will be no video to play. When the pop-up opens again, it will open the default iframe in your widget until you close it again.

    Hope this helps!

    Thread Starter criticnic

    (@criticnic)

    Anyone have any ideas on this? Still have not been able to figure it out. Just to recap: it ONLY works when using it in the Text editor, when switching back to Visual, WordPress instantly adds double-quotes around the src attributes which breaks the images. Thanks!

    It looks like you’ve managed to get it to work. May I ask how you did? I’m running into the same issue.
    Thanks!
    -Nic

    Thread Starter criticnic

    (@criticnic)

    Thanks for the response. I can add the shortcode in the Visual Editor, however where the problem occurs is when I want to add an image as the trigger in the title attribute of the shortcode. If i do this in the Visual Editor, wordpress automatically puts double-quotes around any attributes within the img tag (class and src as shown in my example). Those double quotes cause the image to not show up when the page is published. So to fix it, I go to Text Editor and make them single quotes, which works until you switch back to Visual, where double quotes are automatically replaced again.

Viewing 5 replies - 1 through 5 (of 5 total)