Create link to Phocagallery

Phoca Gallery - image gallery extension
massikk
Phoca Member
Phoca Member
Posts: 40
Joined: 09 Nov 2019, 14:39

Create link to Phocagallery

Post by massikk »

Hi, I have a question.
My gallery have a lot of categories and I can put all in my menu... In menu I insert only link to all categories.
How I can link a specific category in one article of Joomla? I don't want copy and past url because If change link with router of joomla ( Url rewrite ) my link will broken.
I need plugin or other method to create correct link ( index.php?option=com_phocagallery etc etc )
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49138
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Create link to Phocagallery

Post by Jan »

Hi, yes, the easiest way is to just copy the constant link (mostly it does not change). But to get such link dynamically created, just see other Phoca Gallery plugins where these links are used, e.g. Phoca Gallery Content Plugin:

Code: Select all

PhocaGalleryRoute::getImageRoute($image->id, $image->catid, $image->alias, $image->catalias);
JRoute::_(PhocaGalleryRoute::getCategoryRoute($category->id, $category->alias));
to copy or recreate them in your content plugin :idea:

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