WordPress.org

Ready to get started?Download WordPress

Forums

Shortcodes stopped working in custom fields (6 posts)

  1. grahamenglish
    Member
    Posted 4 months ago #

    All of a sudden my shortcodes stopped working in my theme and custom fields. Any idea what could have happened? Was it the most recent 3.8.2 update? Earlier this week everything was working fine.

    Thanks!

  2. Gregg Banse
    Member
    Posted 4 months ago #

    What theme? Did you check the theme authors support forum? What shortcodes? Did they come with the theme? Link?

  3. grahamenglish
    Member
    Posted 4 months ago #

    Thanks for answering. Something changed in the way shortcodes were rendered with the latest update so I just had to update my code a bit. Plus, a plugin got updated at the same time that threw a wrench in things. We're back up and running so I appreciate you coming in and helping.

  4. brooksdc
    Member
    Posted 4 months ago #

    grahamenglish - I'm experiencing this issue as well since this update. Can you share what you know about the shortcode update, and what you needed to do to fix?

    Any help appreciated. Thanks

  5. grahamenglish
    Member
    Posted 4 months ago #

    My developer took care of the problem. We had to adjust the code:

    <?php $downloadlinks = get_post_meta($post->ID, 'downloadlinks', $single = true); 
    
    if ($downloadlinks==''&& is_user_logged_in()){
    	$downloadlinks = print '<ul><li>There are no download links currently available.</li></ul>';
    } else {
    	if ( is_user_logged_in() ) { $downloadlinks = do_shortcode($downloadlinks); }
    };
    
    ?>

    Not sure if this helps. Hope it does.

  6. brooksdc
    Member
    Posted 4 months ago #

    Thanks for the reply. My problem appears to be different than this unfortunately

Reply

You must log in to post.

About this Topic

Tags