[wp-trac] [WordPress Trac] #31574: the_content() displaying URL for embedded audio instead of player

WordPress Trac noreply at wordpress.org
Mon Mar 9 16:08:34 UTC 2015


#31574: the_content() displaying URL for embedded audio instead of player
--------------------------+-----------------------------
 Reporter:  jkatcher      |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 Hi all,

 I have searched other tickets but wasn't able to successfully incorporate
 the responses - I'm also pretty new with wp so apologies and thanks so
 much in advance.

 The issue is that when I'm retrieving content from my post in a loop, I'm
 able to pull the title and other attributes, but the player doesn't show
 up or when it does, it shows the code only.  I can see it fine from the
 'preview post', but when it's generated from the search, it doesn't show
 up.

 Site - http://music.nicemanners.tv


 Code from within individual post:
 {{{
 [audio mp3="http://music.nicemanners.tv/wp-
 content/uploads/2015/03/NM-7000.mp3"][/audio]

 [za_show_download_button text="Download the file"]
 }}}

 Loop code:

 {{{
 <?php if ( $wpus_results->have_posts() ) : ?>

         <?php while ( $wpus_results->have_posts() ) :
 $wpus_results->the_post(); ?>

                 <div class="post" id="post-<?php the_ID(); ?>">
                         <br><?php the_title(); ?>
                         <br><?the_tags(); ?>
                         <br><?the_content(); ?>
                 </div>

         <?php endwhile; ?>

         <?php if(wpus_option('clear_search')) { ?>
                 <br><a id="wpus-clear-search" class="<?php echo
 wpus_option('clear_search_class') ?>" href="#"><?php echo
 wpus_option('clear_search_text'); ?></a>
         <?php } ?>

         <?php wp_reset_postdata(); ?>

 <?php else : ?>

                 <div class="wpus-no-results"><?php echo
 wpus_option('no_results_msg'); ?></div>

 <?php endif; ?>
 }}}

--
Ticket URL: <https://core.trac.wordpress.org/ticket/31574>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list