Forum Replies Created

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

    (@roman75)

    Thank you for the credits.

    Because we needed some customizations i made some changes to your plugin.

    Feel free to integrate the following code:

    1) Added Shortcode for hiding the post date and show the post thumbnail image

    // hide post date with [ ... showdate=no]
    // line ~ 459
    	if ( isset ($atts['showdate']))
    	{
    		$showdate = false ;
    	}
    	else
    	{
    		$showdate = true ;
    	}
    
    // show thumbnail
    	if ( isset ($atts['showthumbnail']))
    	{
    		$showthumbnail = true ;
    	}
    	else
    	{
    		$showthumbnail = false ;
    	} 
    [...]
    // line ~522 after title:
    </a></strong>
    	<?php
    	if($showdate)
           {
    	  echo "&nbsp;&nbsp;&nbsp;(" .  $x->post_date  . ")";
    	}
    [...]
    if ($atts['showall'])
    			{
    				echo "<em>(status = " . $x->post_status . ")</em>" ;
    			}
    			echo "<br>" ;
    			
    // show thumbnail with class "globalImageStyle"
    			if($showthumbnail)
    			{
    				echo get_the_post_thumbnail( $page->ID, 'thumbnail', array( 'class' => 'globalImageStyle' ) );
    				
    			}
    
Viewing 1 replies (of 1 total)