Jump to content


These Forums Are Now Read-Only


For TubePress support, please post a question here or open a support ticket and we will be glad to assist.


Photo

Playlist shortcode not working


  • Please log in to reply
15 replies to this topic

#1 Zalman Kravitz

Zalman Kravitz

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 14 November 2012 - 03:09 PM

Hello,

I am trying to setup a page using a youtube playlist as the source. I have tried both setting it in the settings and with the following shortcode.

[tubepress mode="playlist" playlistValue="061D914B66D2A0AF"]

The actual URL is http://www.youtube.c...61D914B66D2A0AF

Note that i omitted the PL part as per recent discussion.

Any ideas whats causing this. We are running WP version 3.1.4 (for the time being we cant upgrade for a few days because of other upgrades going on)

Best,

-Yosef

#2 eric

eric

    Lead Developer

  • TubePress Staff
  • 2787 posts

Posted 14 November 2012 - 09:44 PM

It seems that over the past 24 hours YouTube has introduced a change in their API which is causing all sorts of breakage for anyone using TubePress to display a playlist. If you're reading this, that probably means you!

  • As this appears to be a problem on YouTube's end, I have filed a bug report with them. Please star this issue to draw their attention!

  • I've also posted a question on stackoverflow, as this is YouTube's official support forum for their API. Please vote on this question to draw attention to it!.

Please, before you continue reading this post, take action on the two items above. The more noise we can make about this, the faster it will be addressed by YouTube! Now, here is a workaround:

  • Open up tubepress/sys/classes/org/tubepress/impl/bootstrap/TubePressBootstrapper.class.php with your favorite text editor.

  • Comment out lines 145 and 146. That will change the code in that area from

    $pm->registerFilter(org_tubepress_api_const_plugin_FilterPoint::OPTION_SET_PRE_VALIDATION,    $ioc->get('org_tubepress_impl_plugin_filters_prevalidationoptionset_StringMagic'));$pm->registerFilter(org_tubepress_api_const_plugin_FilterPoint::OPTION_SET_PRE_VALIDATION,    $ioc->get('org_tubepress_impl_plugin_filters_prevalidationoptionset_YouTubePlaylistPlPrefixRemover'));
    to

    $pm->registerFilter(org_tubepress_api_const_plugin_FilterPoint::OPTION_SET_PRE_VALIDATION,    $ioc->get('org_tubepress_impl_plugin_filters_prevalidationoptionset_StringMagic'));//$pm->registerFilter(org_tubepress_api_const_plugin_FilterPoint::OPTION_SET_PRE_VALIDATION,//    $ioc->get('org_tubepress_impl_plugin_filters_prevalidationoptionset_YouTubePlaylistPlPrefixRemover'));

  • Ensure that your anytime you use a playlist ID with TubePress, it is prefixed with "PL". i.e. this will work

    [tubepress mode="playlist" playlistValue="PL83FF64CDA043CBC4"]
    while the following will not work

    [tubepress mode="playlist" playlistValue="PL83FF64CDA043CBC4"]
This is ugly and hacky, but it will restore your playlist-based galleries to working order - at least until YouTube addresses this issue.

#3 rodmusic

rodmusic

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 14 November 2012 - 11:10 PM

Under part 3 of your workaround the "will work" and "won't work" look the same to me. I added the PL prefix to my playlist ID numbers and the videos are now showing. I didn't comment out the code, though, but it worked anyway.

#4 Liam kaid

Liam kaid

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 14 November 2012 - 11:34 PM

With "PL" or without "PL" is not working for me since today :(

#5 Eric Alexander

Eric Alexander

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 15 November 2012 - 04:35 AM

I have always used the Playlist ID prefixed "PL" and the video gallery was working, but since this morning, even with the "PL" prefix the videos have disppeared and what we see is "Playlist not found"

I have installed Tubepress 2.4.4. whereas 2.4.5 is now available. If I upgrade to 2.4.5., will the Playlist start working again ?

#6 Eric Alexander

Eric Alexander

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 15 November 2012 - 04:37 AM

One more question and that is, how and by whom can this problem be fixed ? Is it Youtube/Google or Tube Press that can fix it ?

#7 John L

John L

    Newbie

  • TubePress Pro
  • Pip
  • 4 posts

Posted 15 November 2012 - 05:01 AM

Thank you for your support - Changing the code as you described worked for me.

#8 Nancy Nangeroni

Nancy Nangeroni

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 15 November 2012 - 08:58 AM

Thanks VERY much for this hack, it worked for me too, on www.TransPeopleSpeak.org

#9 John Donovan

John Donovan

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 15 November 2012 - 09:54 AM

Hi, I'm kinda new to any kind of messing with code and I'm having a hard time finding how to access the lines so I can make the switch. I thought I could get to it from my web hosts' control panel, but I can't find it there. Could you please point me in the right direction? Thanks.

http://medicinebreath.com/?page_id=90

Never mind, found it and it worked. Thanks!

#10 Raya Pomelkova

Raya Pomelkova

    Newbie

  • Members
  • Pip
  • 9 posts

Posted 15 November 2012 - 11:18 AM

Thanks Eric - your instructions worked like a charm!

#11 mekong cilture

mekong cilture

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 15 November 2012 - 11:45 AM

Thanks a lot. I have the same problem and I open :tubepress/sys/classes/org/tubepress/impl/bootstrap/TubePressBootstrapper.class.php with notepad---->delete line 145& 146--->coppy and pase://$pm->registerFilter(org_tubepress_api_const_plugin_FilterPoint::OPTION_SET_PRE_VALIDATION,
// $ioc->get('org_tubepress_impl_plugin_filters_prevalidationoptionset_YouTubePlaylistPlPrefixRemover'));

it worked for me too, on http://www.mekongculture.com/?p=4450

#12 Osvaldo Gomez

Osvaldo Gomez

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 15 November 2012 - 12:45 PM

How about for Tubepress pro? It doesn't seem to be working for us even after implementing these changes.

#13 Ron Brajkovich

Ron Brajkovich

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 15 November 2012 - 01:32 PM

I am also having the playlist problem. I need some guidance as to where I can change the code as Eric suggested.

#14 eric

eric

    Lead Developer

  • TubePress Staff
  • 2787 posts

Posted 15 November 2012 - 08:19 PM

According to Google, this has been fixed as of a few minutes ago. Some local testing leads me to believe that things are back to normal. If you're still experiencing trouble, please open up a new discussion thread here in the forum and we'll get you squared away.

Thanks!

#15 Liam kaid

Liam kaid

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 15 November 2012 - 08:51 PM

So i did the TubePressBootstrapper.class.php modification and that worked... So I changed lots of playlists to add the "PL"

But now since the Youtube fix everything is working and I have some playlists with "PL" and others withoult the "PL" all working... So should I change the playlists code? Should I remove or add the "PL" in the next playlists?

#16 eric

eric

    Lead Developer

  • TubePress Staff
  • 2787 posts

Posted 15 November 2012 - 09:21 PM

So i did the TubePressBootstrapper.class.php modification and that worked... So I changed lots of playlists to add the "PL"

But now since the Youtube fix everything is working and I have some playlists with "PL" and others withoult the "PL" all working... So should I change the playlists code? Should I remove or add the "PL" in the next playlists?


There's no need to change your playlist identifiers, even if you performed the modification to TubePressBootstrapper.class.php. YouTube claims that they will accept the leading "PL" and simply ignore it.