News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Get current page URL, without the parameters?

Started by EvanGR, January 08, 2019, 12:25:07 PM

Previous topic - Next topic

EvanGR

Hello,

I want to get the current page URL, excluding the parameters...
e.g. /mycategory/mysubcategory?param=1
The above, without the bold part.

Reason: I want to create custom page variation links with my own parameters.

I want to do it from the product category view file, if that makes any difference (it shouldn't).

Any ideas?

Thanks

AH

Regards
A

Joomla 3.10.11
php 8.0

PRO

$jinput = JFactory::getApplication()->input;
$category=$jinput->getInt('virtuemart_category_id', 0);


$category_url = JRoute::_ ( 'index.php?option=com_virtuemart&view=category&virtuemart_category_id=' . $category , FALSE);