WordPress.org

Ready to get started?Download WordPress

Forums

SoundCloud Is Gold
[resolved] Jetpack shortcode compatibility fix: how to (10 posts)

  1. realtm
    Member
    Plugin Author

    Posted 2 years ago #

    Solution 1:

    You can disable jetpack shortcode options but it will disable all jetpack shortcodes: In your dashboard, click jetpack in the sidebar, click deactivate on the Shortcode Embeds box.

    Solution 2:

    Comment one line in the jetpack plugin. This has to be done every time you update jetpack: In your dashboard, click editor under plugin in the sidebar, on the top right corner select jetpack by wordpress.com in the dropdown menu, click select. Click on jetpack/modules/shortcodes.php in the list below, then click on jetpack/modules/shortcodes/soundcloud.php. In the editor find this line add_shortcode( "soundcloud", "soundcloud_shortcode" );
    and replace it with
    //add_shortcode( "soundcloud", "soundcloud_shortcode" );.

    The jetpack plugin basically bring many shortcodes with itself. It's great if you're only using jetpack and if you're happy with their basic shortcodes.

    This fix can work for any of the shortcodes. you just need to select jetpack/modules/shortcodes/vimeo.php for vimeo, jetpack/modules/shortcodes/youtube.php for youtube, etc... and comment the line that add the shortcode.

    http://wordpress.org/extend/plugins/soundcloud-is-gold/

  2. djgmani
    Member
    Posted 2 years ago #

    HELP i tried to do this but instead of changing it to jetpack it was still on akismet

    now my site says

    Parse error: syntax error, unexpected $end in /home/djgmani/public_html/wp-content/plugins/jetpack/modules/shortcodes/soundcloud.php on line 59

    i can't undo or reload or login to my adin... please help

  3. djgmani
    Member
    Posted 2 years ago #

  4. Tim Moore
    Moderator
    Posted 2 years ago #

    djgmani, try deleting the Jetpack folder via FTP. Then reinstall.

    What exactly are you attempting to do? If you'd prefer Jetpack's shortcode over Soundcloud is Gold's, then you should be able to disable Soundcloud is Gold rather than modify Jetpack's code.

    Please let me know how I can help further.

  5. realtm
    Member
    Plugin Author

    Posted 2 years ago #

    Thanks Tim for taking the time to reply to djgmani. I love it when people help each others :)

    @DJGmani
    This post is about disabling jetpack's soundcloud shortcode so it doesn't conflict with soundcloud is gold plugin. By the way I think I found a fix for that and I will implement it in the next release.

  6. Evnmove
    Member
    Posted 2 years ago #

    Thank you Realtm, great solution!!! I had the same problem since installing statistics for wordpress and then jetpack after Joomla recommendation. Thank you for replying to the request

  7. thesultan
    Member
    Posted 2 years ago #

    It looks like Jetpack is now compatible with the soundcloud-is-gold plugin after the new soundcloud html5 release. I have them running together on my wordpress installation. It won't display at first when i had the standard flash player selected, but worked with no issues once i switched it to the new html5 player. No need for any hacks.

  8. realtm
    Member
    Plugin Author

    Posted 2 years ago #

    That's great news! I'm guessing that the system that jetpack is using by default for soundcloud hasn't implemented the html5 player yet.

    :)

  9. carlfj
    Member
    Posted 1 year ago #

    Instead of modifying the plugin every time it is updated, I'd recommend to make the modification in the theme instead.
    By adding a few lines of code to the functions.php in the theme, it is possible to remove the wrong shortcode and replace it with the SoundCloud Is Golden version:

    if(function_exists('soundcloud_is_gold_shortcode')) {
    	remove_shortcode('soundcloud');
    	add_shortcode('soundcloud', 'soundcloud_is_gold_shortcode');
    }

    It might be preferable to has it added as an action instead, but I couldn't figure out which action hook to use.

    Edit:
    Apparantly the HTML5 embed has been implemented in Jetpack, but it requires the user to enable the feature in the profile settings here:
    http://soundcloud.com/settings/extra
    Though, to have both plugins working at the same time it is still necessary to make the modification above.

  10. realtm
    Member
    Plugin Author

    Posted 1 year ago #

    thanks carlfj!

    I was going to add something along those lines in the plugin but never got around doing it.

    Thanks for sharing

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic