Add links into Titles ?

Phoca Gallery - image gallery extension
mishef
Phoca Member
Phoca Member
Posts: 19
Joined: 04 Jul 2011, 14:20

Add links into Titles ?

Post by mishef »

Hello!

For seo reasons i want to make titles of my images linkable: http://i.imgur.com/N0B5Z.png

In my parametars images are in "Detail View".

Is any way to do that ?? :x
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49160
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Add links into Titles ?

Post by Jan »

Hi, then this needs to be customized in the template of Phoca Gallery - add the url to the items:

components/com_phocagallery/views/category/view.html.php
components/com_phocagallery/views/category/tmpl/default.php

Jan
If you find Phoca extensions useful, please support the project
mishef
Phoca Member
Phoca Member
Posts: 19
Joined: 04 Jul 2011, 14:20

Re: Add links into Titles ?

Post by mishef »

Thanks for directions.

For thoose who want the same thing.

Go to components/com_phocagallery/views/category/tmpl/default.php

Go to Line 245 and search for:

// image
if ($value->type == 2) {
if ($value->displayname == 1) {
echo '<div class="phocaname" style="font-size:'.$this->tmpl['fontsizename'].'px">'
.PhocaGalleryText::wordDelete($value->title, $this->tmpl['charlengthname'], '...').'</div>';


and replace it with:

// image
if ($value->type == 2) {
if ($value->displayname == 1) {
echo '<a href="'. $value->link.'"><div class="phocaname" style="font-size:'.$this->tmpl['fontsizename'].'px">'
.PhocaGalleryText::wordDelete($value->title, $this->tmpl['charlengthname'], '...').'</div></a>';
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49160
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Add links into Titles ?

Post by Jan »

Ok, thank you for the guide.

Jan
If you find Phoca extensions useful, please support the project
Post Reply