Welcome! To use this support forum, please Login or Join Today!

You are here → Home :: Forum Home :: General WordPress :: Plugins Discussion :: Thread

   

Theme Default Slider: Show Title and Caption Problem

{name}
Rank

Total Posts: 16

Joined 2011-05-09

PM

 
Regarding the default slider that is integrated with Simplethemes themes:

In the individual slide parameters settings, if the "Show Title" is turned ON, BUT there is nothing in the "Slide Caption" box, the title does NOT show on the slide. There must be some text (just one character will work) in the "Slide Caption" box for the Title to show in the slide. At that point BOTH the title and caption show.

If the "Show Title" is turned OFF, BUT there is any text in the "Slide Caption" box, both the TITLE and that Caption Text show in the slide.

It seems, from the way the parameters are setup, that you should be able to have the title display WITHOUT the caption, or the caption display WITHOUT the title.

Thanks for any help.
{name}
RankRankRankRank

Total Posts: 3667

Joined 2011-04-27

PM

 
The "Show Title" setting affects the slide in two cases:

1. ) When the slide type is a text slide (anything other than a full size image).
2. ) When captions are enabled.

I can see how this can be a little confusing for some so I've updated the framework to include this which will hide the title in both captions and text slides. I'll push this update out tonight.

In /wp-content/{themename}/lib/functions/content_functions.php

Change:

 if (!$slidecaption == '') {
 // $result.= '<div class="slide_caption"><p>'.$slidecaption.'</p></div>';
 $result.= '<div class="slide_caption"><span class="title">'.get_the_title().'</span><p>'.$slidecaption.'</p></div>';
 }


to:

if (!$slidecaption == '') {
// $result.= '<div class="slide_caption"><p>'.$slidecaption.'</p></div>';
$result.= '<div class="slide_caption">';
 if ($showtitle == 'yes') {
 $result.='<span class="title">'.get_the_title().'</span>';
 }
$result.='<p>'.$slidecaption.'</p></div>';
}

{name}
Rank

Total Posts: 16

Joined 2011-05-09

PM

 
Thanks for the explanation and the code.

Much appreciated.