Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Trying to change image title.  (Read 2996 times)

0 Members and 1 Guest are viewing this topic.

aunrea

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Female
  • Posts: 36
    • Spot Design
Trying to change image title.
« on: October 03, 2007, 10:55:42 pm »

I am trying to change the image title to the title of the image instead of the filename. This is what I have:

Code: [Select]
$options = array("imageattributes" => array("alt" => '{{pTitle}}', "title" => '{{pTitle}}'));
$objCpm->cpm_viewLastAddedMedia(1, 4, $options);

The images show up but the image title is still the filename and when looking at the code I see:

Code: [Select]
<table  >
<tr>
<td><a href="http://portfolio.spot-design.net/displayimage.php?pos=-279"  ><img  src="http://portfolio.spot-design.net/albums/digiscrap/papers/thumb_cduffy_Zita_PP15.jpg" alt="cduffy_Zita_PP15.jpg" title="cduffy_Zita_PP15.jpg" alt="{{pTitle}}"  title="{{pTitle}}"   /></a><br /></td>
<td><a href="http://portfolio.spot-design.net/displayimage.php?pos=-280"  ><img  src="http://portfolio.spot-design.net/albums/digiscrap/papers/thumb_cduffy_Zita_ScallopOverlay.png" alt="cduffy_Zita_ScallopOverlay.png" title="cduffy_Zita_ScallopOverlay.png" alt="{{pTitle}}"  title="{{pTitle}}"   /></a><br /></td>
<td><a href="http://portfolio.spot-design.net/displayimage.php?pos=-277"  ><img  src="http://portfolio.spot-design.net/albums/digiscrap/papers/thumb_cduffy_Zita_PP13.jpg" alt="cduffy_Zita_PP13.jpg" title="cduffy_Zita_PP13.jpg" alt="{{pTitle}}"  title="{{pTitle}}"   /></a><br /></td>
<td><a href="http://portfolio.spot-design.net/displayimage.php?pos=-278"  ><img  src="http://portfolio.spot-design.net/albums/digiscrap/papers/thumb_cduffy_Zita_PP14.jpg" alt="cduffy_Zita_PP14.jpg" title="cduffy_Zita_PP14.jpg" alt="{{pTitle}}"  title="{{pTitle}}"   /></a><br /></td>
</tr>
</table>

How do I get it to change the title and alt to the image title I set in Coppermine? I do have image titles set for those images too. You can see the title in my coppermine gallery (which is v. 1.4.13).

The website I have this on is http://spot-design.net. My coppermine gallery is at http://portfolio.spot-design.net.

Thanks for any help.
Logged
Pages: [1]   Go Up
 

Page created in 0.018 seconds with 20 queries.