Can't see title?

Permalink Browser Info Environment
Hi,
Great add-on. Descriptions are showing nice, but I can't get titles (Concrete 5.6.1.2)?

Tom

Type: Discussion
Status: In Progress
thuic
View Replies:
shahroq replied on at Permalink Reply
shahroq
Hi,
The title field is just use for image tab/title of img tag.
tjcam856 replied on at Permalink Reply
tjcam856
This is a great add-on! It would be even better if it could display the title. I'm not very good with php but wondering if you could explain how to display the title. I would like to display it above the caption.

Thanks
Tom
shahroq replied on at Permalink Reply
shahroq
You can always type title at the description area to display at the slider caption. but if you need to add title field to caption just open:
\packages\whale_nivo_slider\blocks\whale_nivo_slider\view.php
and edit this line (line 16):
echo '<img src="'.$f->getRelativePath().'" alt="'.$item['itemTitle'].'" title="'.$item['itemDesc'].'" data-thumb="'.$f->getRelativePath().'" >';

to
echo '<img src="'.$f->getRelativePath().'" alt="'.$item['itemTitle'].'" title="'.$item['itemTitle']."<br>".$item['itemDesc'].'" data-thumb="'.$f->getRelativePath().'" >';
chai714 replied on at Permalink Reply
chai714
Hi,

Does this code still apply to the latest version? I am not seeing your code on the version I'm using.

Thanks!
shahroq replied on at Permalink Reply
shahroq
Yep, it should.
chai714 replied on at Permalink Reply
chai714
Here's the entire contents of view.php in the version I'm using:

<?php   
/**
 * @author       shahroq <shahroq \at\ yahoo.com>
 * @copyright     Copyright (c) 2013 shahroq.
 *http://killerwhalesoft.com/c5/addons/...
 */
defined('C5_EXECUTE') or die("Access Denied."); 
?>
   <div class="slider-wrapper <?php  echo "theme-".$theme_title;?>" id="<?php  echo "slider-wrapper-".$bID; ?>">
       <div id="<?php  echo "nivo-slider-".$bID; ?>" class="nivoSlider" style="width: 100% !important;">
      <?php   
      foreach($items as $item) { 
         echo (strlen($item['itemUrl'])>1) ? '<a href="'.$item['itemUrl'].'">' : '';
           echo '<img src="'.$item['itemImageSrc'].'" alt="'.$item['itemImageAlt'].'" title="'.$item['itemImageTitle'].'" data-thumb="'.$item['itemImageSrc'].'" >';
         echo (strlen($item['itemUrl'])>1) ? '</a>' : '';
shahroq replied on at Permalink Reply
shahroq
Yep, it's the same, just replace code mentioned above and it will work.

concrete5 Environment Information

Browser User-Agent String

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You have not specified a license for this support ticket. You must have a valid license assigned to a support ticket to request a refund.