Change image title - Facebook upload

Phoca Gallery - image gallery extension
Matezek
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 20 Sep 2012, 20:07

Change image title - Facebook upload

Post by Matezek »

Hi all,

I would like to change image name of Facebook uploads,

Actually, I've "Image 001" (etc), but I want have "Category name 001"...

Someone know how I can solve that ?

Thanks !
CU
Matezek
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 20 Sep 2012, 20:07

Re: Change image title - Facebook upload

Post by Matezek »

So, after few hour, I've found solution ! :P

I don't thing it's the better solution, but it's work ! 8)

For J2.5, PG v3.2.1 :
Go to administrator/components/com_phocagallery/models/
Open phocagalleryc.php, at line 488 (function loadExtImagesFb()) :
Default : $noImageTitle = 'Image ' . str_pad($i + 1, 3 ,'0', STR_PAD_LEFT);

Change to : $noImageTitle = PhocaGalleryText::wordDelete($albumName, 17, '...').' <br/>Photo ' . str_pad($i + 1, 3 ,'0', STR_PAD_LEFT);
The value "17" it's for truncate name's Facebook album. You can give all value you want.

Alternative : $noImageTitle = $albumName.' - Photo ' . str_pad($i + 1, 3 ,'0', STR_PAD_LEFT);

Before :
Image
After :
Image

Hope that can help anyone else !

See you !
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49150
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Change image title - Facebook upload

Post by Jan »

Hi, thank you for the information.

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