WordPress.org

Forums

liveTV Bundle
Does LiveTV cause jQuery to load differently? (other plugins break) (12 posts)

  1. polynatiag
    Member
    Posted 3 years ago #

    Hi,

    Sorry for starting another support thread - I thought I had it all working now. Seems I still have another issue:

    I use TubePress & NextGEN Gallery as well. They work fine - no errors FireBug says, however once I start enabling LiveTV an error shows up: "Caught exception when booting TubePress: TypeError: Cannot read property 'cycleW' of undefined" ( tubepress.js:1)

    I first thought this was caused by Tubepress since it mentions that plugin. However, once I disabled LiveTV Bundle the error was gone again. I enabled it again, and TubePress and NextGEN Gallery stopped working after that.

    So I think that LiveTV Bundle is causing it, but I'm not sure what is happening exactly and if I need to look for a fix in WordPress or another plugin.

    Hope you can help me out once more. Thank you!!

    PS. I think it was jquery related because the developer of the Tubepress plugin told me jQuery was being loaded after the plugins were loaded (so too late). I then looked for issues with wp_head() but came to the conclusion that this function was being properly called/used. The NextGEN Gallery also has a built-in checker for wp_head() calls and it verifies this is working correctly as well.

    http://wordpress.org/extend/plugins/livetv-bundle/

  2. KwarK
    Member
    Plugin Author

    Posted 3 years ago #

    jQuery to load differently?

    No. The plugin uses a maximum of wordpress standard for all php script and the default wordpress standard to enqueue/register all scripts.

    wp_register_script('script', 'src_to_the_script', array('dependance'));

    where dependance is attached to the default jquery version includes by wordpress and in wordpress.

    and after all wp_enqueue_script are loaded only if it is necessary and in the page where shortcode is.

    A better way to view where the problem comes from, it's to make a search on cycleW for all your files in your wp-content folder and looks if one javascript library is loaded maybe two times (your theme, one plugin, and this plugin).

    http://tubepress.org/demo/ (same result pagination). Maybe tubepress used the same JQuery extension for pagination.

  3. KwarK
    Member
    Plugin Author

    Posted 3 years ago #

    If it's the fact, you may stop the load of JQuery extension for pagination and makes test to view if the pagination yet works after this stopping.

    you may delete in /page-frontend/page-livestream.php ~line 293

    wp_enqueue_script('livetv-pagination');

  4. KwarK
    Member
    Plugin Author

    Posted 3 years ago #

    cycleW comes from a JQuery extension and it's loaded for the slide effect between the div share/div Chat.

    A maximum of the necessary JQuery code/JQuery extensions/JQuery dependancies for my plugin are loaded only if it's the page where the shortcode is.

    (except q-tip because it is necessary also for the widget)

  5. polynatiag
    Member
    Posted 3 years ago #

    Hi,

    Commenting out didn't break anything, but it didn't fix it either. Error remains the same. I searched for cycleW as you said. This is the output:
    http://pastebin.com/raw.php?i=c1vZzLKF

    Looking at this, it seems that NextGEN is interfering? Though is there anything that can be done to fix that?
    I don't need the slider on the top (IRC/Share) so I did delete that in the php code as you suggested in another thread. It didn't fix the problem though. (I have the widget completely disabled as well, so it's probably not that either)

    Thank you in advance,

  6. KwarK
    Member
    Plugin Author

    Posted 3 years ago #

    frontend.js is an extension for JQuery

    /*
    * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/
    * TERMS OF USE - jQuery Easing
    * Open source BSD License.
    * Copyright © 2008 George McGinley Smith
    * All rights reserved.
    */

    comment in /page-frontend/page-livestreams.php @line ~ 55

    wp_enqueue_script('livetv-beautiful-effect');

    to stop this load for the plugin (but it's preferable, to stop the load of your slider/Lightbox if the slider/Lightbox isn't displaying on that page...).

    why the php code for the sliderpost/Lightbox, loads its js file everywhere while there are needs that only where the sliderpost/Lightbox is displayed ? Now you must changes the liveTV code (@risk for css bugs) for another plugin...

  7. polynatiag
    Member
    Posted 3 years ago #

    Thanks, - however nothing changed when I commented it out. I did clear the cache.

    If it helps to see the error yourself:
    Add this in the hosts file, the site is not online yet so need to manually set the IP/hostname:
    178.79.129.186 obeygaming.com www.obeygaming.com

    The site is: https://obeygaming.com/community/
    You can see the Livestreams, Videos (TubePress) and screenshots there. You'll see that the thumbnails under Videos aren't clickable, and when opening screenshots it doesn't open in a Lightbox.

    Thank you,

  8. KwarK
    Member
    Plugin Author

    Posted 3 years ago #

    I have editing my previous message when you answered. View the previous message.

  9. polynatiag
    Member
    Posted 3 years ago #

    I'm sorry - I'm a bit confused:

    From what I understand the actual issue is that NextGEN Gallery loads its .js files on all pages, so including the ones where it is not needed/shouldn't be loaded. This messes up LiveTV, which needs some of the same functionality from certain files, thus messing up because it's being used twice. Correct?

    Now the workaround should be to comment the following, even though it's kind of a "hack", and not the best solution:
    wp_enqueue_script('livetv-beautiful-effect');

    I did comment this out, but the issue was not fixed. So can we be sure this is the problem?

    I agree that NextGEN shouldn't load when it's not needed, and I will also make a support thread there. However, if there is a temporary fix possible that would be great.

    Thanks :)

  10. polynatiag
    Member
    Posted 3 years ago #

    Hi,

    It seems that there's actually a plugin to let NextGEN Gallery only load when required: NextGEN Gallery Optimizer. This seems to have fixed the issue partially. Another problem now occurs: On other pages (not LiveTV)I get the following error:

    [cycle] terminating; too few slides: 0 frontend.js:8
    
    Uncaught TypeError: Cannot call method 'hide' of undefined jquery.fancybox-1.3.4.pack.js:18
    H jquery.fancybox-1.3.4.pack.js:18
    C jquery.fancybox-1.3.4.pack.js:19
    a.fn.fancybox jquery.fancybox-1.3.4.pack.js:38
    f.event.dispatch jquery.js:3
    f.event.add.h.handle.i jquery.js:3

    On the following page for example: https://obeygaming.com/community/media/screenshots/
    The error occurs once you click a screenshot. The frontend.js there points to a LiveTV file, even though this is not a LiveTV page. Could that be causing the issue now?

    Thanks!

  11. polynatiag
    Member
    Posted 3 years ago #

    Alright I've been trying stuff out again and got something that might(?) help...

    The Uncaught Call method 'hide" error was a side-effect of the new plugin: NextGEN Gallery Optimizer. I've now fixed this error (though it did not fix my gallery with LiveTV enabled)

    I've disabled plugins one-by-one to figure out which one specifically was causing it.
    I think there's 2 different addons combining multiple problems for other addons:

    Once I fixed the Uncaught TypeError, the cycle remained, and it's caused by LiveTV Team - 2 - Display Lives. I believe it is loading on all the pages while it should only load on the LiveTV page. So that's one.

    The other issue is probably TubePress. This is also loading on all pages, while it should only load on one of them. I tried renaming the frontend.js file to see if it'd make a difference, only to see it replaced by another error caused by Tubepress. So that's probably the second problem.

    Hoping this'll help with fixing the problem. I really hope it's possible to run both the plugins at the same time, heh.

    Thanks again,

  12. polynatiag
    Member
    Posted 2 years ago #

    Hi,

    As an update - I've changed some things around addon wise. The "[cycle] terminating; too few slides: 0 frontend.js:8" error remains now, but this doesn't seem to interfere with how the site works. It seems to work fine now.

    So - thank you for all the help. Glad everything is working now. Thank you!

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • liveTV Bundle
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic