Gallery Attributes - Addition

Permalink
I have extended the purchased gallery block with additonal data attributes but am having trouble displaying them when the image is viewed.
I can only display one attribute at a time by changing the echo imgInfo caption portion of the statement in the view.php file. I have tried to extend this statement by adding the mydata value as shown in the second code block below but get errors....syntax help is appreciated.

This first codeblock shown sets the caption variable.

Thanks,
-mark

<?php  $caption = array_key_exists('caption', $imgInfo) ? $imgInfo['caption'] : $f->getTitle();?>


<a href="<?php echo $f->getRelativePath()?>" title="<?php echo $imgInfo['caption' , 'mydata']?>"<?php $ih->outputThumbnail($f,$thumbnailWidth,$thumbnailHeight,''); ?></a>

marxion
 
marxion replied on at Permalink Reply
marxion
I now can display all the attributes but echoing a line break via "\n" doesn't work. Any ideas...here's my code.

Thanks
-mark

<?php  $caption = array_key_exists('caption', $imgInfo) ? $imgInfo['caption'] : $f->getTitle();?>
            <?php  if($i % $thumbnailPerRow == 0) {?>
               </tr><tr>
            <?php  } ?>      
            <td id="file_<?php echo $imgInfo['fID'];?>" class="galleryImages">
               <a href="<?php echo $f->getRelativePath()?>" title="<?php echo $imgInfo['caption'] , "\n", $imgInfo['type'] , "\n", $imgInfo['shape'] , "\n", $imgInfo['color']?>"<?php $ih->outputThumbnail($f,$thumbnailWidth,$thumbnailHeight,''); ?></a>
wizardontherun replied on at Permalink Reply
wizardontherun
looking for HTML i would think
Tony replied on at Permalink Reply
Tony
you need a closing > before you output the thumbnail.
marxion replied on at Permalink Reply
marxion
I tried the BR echo and still not breaking the data in the line. Closing with the A tag prior to rendering the thumbnail does not allow the thumbnail to be launched in the lightbox.

Thanks for the suggestions

-mark
Tony replied on at Permalink Reply
Tony
well, you have to close the <a> tag, otherwise you're going to have issues. Maybe the code you pasted got copied wrong, but in your example it looks like

<a href="stuff" title="stuff" <img></a>


can you attach the source of the HTML that's produced from this code?
marxion replied on at Permalink Reply 1 Attachment
marxion
This is the view.php and controller.php file that comes with the purchased image gallery. I added the attributes type / shape / color after extending the db.xml adding to the database.

-mark
Tony replied on at Permalink Reply 1 Attachment
Tony
well, I was hoping you'd attach you source html (View Source in most browsers)
I'm not too sure what you were doing with all the , "\n" , things in your title tag, but give the attached file a try.
marxion replied on at Permalink Reply
marxion
Much appreciated....as always!

-mark