• Hello,

    So I have been surfing a lot trying to find the additional code to add to display image titles. The code I’m currently using to show the slideshow which is working is

    <?php if ( function_exists( 'meteor_slideshow' ) ) {
    
    	if ( is_front_page() ) {
    		meteor_slideshow( '' );
    	} if ( is_page( 'video' ) ) {
    
    		meteor_slideshow( 'videos-statics' );
    	} if ( is_page( 'video-games' ) ) {
    		meteor_slideshow( 'videos-statics' );
    	} else {
    		 //get the featured image's title
    
    	$ms_thumb_id = get_post_thumbnail_id($id);
    
    	$ms_title = esc_attr( get_post_field( 'post_title', $ms_thumb_id ) );
    
    	echo '<p>' . $ms_title . '</p>';
    	}
    } ?>

    I tried using the following additions to get the title to show, but it doesn’t work.

    <?php // Get the featured <?php // Get the featured image's title
    
    	$ms_thumb_id = get_post_thumbnail_id($id);
    
    	$ms_title = esc_attr( get_post_field( 'post_title', $ms_thumb_id ) );
    
    	echo '<p>' . $ms_title . '</p>';
    
    ?>

    and this one

    if (changed && opts.pager)
    	{
    		opts.updateActivePagerLink(opts.pager, opts.currSlide, opts.activePagerClass);
    
    //N Nand - Changes to display image alt tag as an title in the slideshow
    		nnCurSlide = opts.currSlide + 1
    		nnImageTitle = $j('div#slide-'+nnCurSlide+' img').attr("alt");
    
    		$j('div.meteor-buttons span').remove();
    		$j('div.meteor-buttons').append('<span>'+nnImageTitle+'</span>');
    	}

    I tried this website to help as well, but it didn’t do me any good. I tried many other open cases such as this and this. The second is not really what I am looking for since I’m not interested in replace paging icons. Im an amateur at all this, but I could use the help.

    Can anyone help?

    https://www.ads-software.com/extend/plugins/meteor-slides/

Viewing 1 replies (of 1 total)
  • Thread Starter ggvogue

    (@ggvogue)

    Figured it out. Need to add <p><?php the_title(); ?></p>

    Before this</div><!-- .mslide -->

Viewing 1 replies (of 1 total)
  • The topic ‘[Meteor Slides] How to display Image Title’ is closed to new replies.