Support » Plugin: Seriously Simple Podcasting » Direct link to OneDrive?

Viewing 13 replies - 1 through 13 (of 13 total)
  • Plugin Contributor Hugh Lashbrooke

    (@hlashbrooke)

    The issue will most likely be due to the fact that your audio file URL is not a direct file reference and instead uses OneDrive’s resid variable.

    I am however, going to release a quick update (v1.9.1) that makes sure the audio player always receives a direct file reference no matter what the saved audio file URL looks like. I should have that update out later today – I will reply again on here once it’s sorted out.

    Cheers,
    Hugh

    Plugin Contributor Hugh Lashbrooke

    (@hlashbrooke)

    I got onto this sooner than expected and the v1.9.1 update is live. Your audio player will now use direct file references no matter what you put into the audio file URL field. Let me know if that sorts things out for you.

    Cheers,
    Hugh

    Seems to be doing something different, but the player doesn’t load:

    http://avondaletest.org/podcast/1-corinthians-141-5/

    Any ideas? Did I do it wrong?

    Plugin Contributor Hugh Lashbrooke

    (@hlashbrooke)

    I’ve never used OneDrive, so not sure how things work there. Could you please check to see if the file is password protected, or otherwise inaccessible? Other than that you’ll need to debug by deactivating all of your other plugins and reverting to a default WordPress theme (e.g. Twenty Twelve) to rule out conflicts.

    Cheers,
    Hugh

    I took a look at this and think I understand the problem. Essentially, OneDrive is providing a link that results in a 302 redirect to the actual file. It seems the WordPress audio player doesn’t follow the redirect. I edited the plugin to use a different audio player (https://www.tipsandtricks-hq.com/wordpress-audio-music-player-plugin-4556) in here:

    public function audio_player( $src = ” ) {

    if ( $src ) {
    return do_shortcode(‘[sc_embed_player fileurl=”‘.$src.'”]’);
    }

    return false;
    }

    This now works (example: http://avondaletest.org/podcast/test/) for both direct links and redirects.

    Any idea how to fix it in the plugin directly as obviously my fix is more of a hack.

    Plugin Contributor Hugh Lashbrooke

    (@hlashbrooke)

    OK interesting, so the issue is actually the WordPress media player not being able to handle that correctly. I’ve logged this as a core bug, so we can see what happens with that (ticket), but in the mean time I’ll add in a filter that allows you to use a different audio player if you would like to do so. For now, you can keep your hacked solution as it is and when I release the next update that includes the filter, I will post on here with a snippet that you can add to your site that will allow you to continue using your alternative media player.

    Thanks for finding the source of the issue here!

    Cheers,
    Hugh

    Plugin Contributor Hugh Lashbrooke

    (@hlashbrooke)

    Just a quick update for you.

    I have released v1.9.4 that includes some performance enhancements for the RSS feed as well as the filter that will allow you to use a different audio player. To use your alternative audio player, add this code to your theme’s functions.php file:

    add_filter( 'ssp_audio_player', 'jakuboleksy_custom_audio_payer' );
    function jakuboleksy_custom_audio_payer ( $player, $src ) {
      $player = do_shortcode( '[sc_embed_player fileurl="' . $src . '"]' );
      return $player;
    }

    Hope that helps 🙂

    Thanks!

    Plugin Contributor Hugh Lashbrooke

    (@hlashbrooke)

    Pleasure 🙂

    Did something break here? I have to change the plugin code, the filter didn’t work. I keep getting a warning saying the second parameter wasn’t provided?

    Plugin Contributor Hugh Lashbrooke

    (@hlashbrooke)

    Nothing changed, but I think WP got a bit more strict with parameter counts. This updates snippet should sort it out for you:

    add_filter( 'ssp_audio_player', 'jakuboleksy_custom_audio_player', 10, 2 );
    function jakuboleksy_custom_audio_player ( $player, $src ) {
      $player = do_shortcode( '[sc_embed_player fileurl="' . $src . '"]' );
      return $player;
    }

    Thank worked, thanks!

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Direct link to OneDrive?’ is closed to new replies.