Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1


Link construction issue 6 years 8 months ago #22173

  • znort
  • znort's Avatar Topic Author
  • Offline
  • Senior Member
  • Senior Member
  • Posts: 42
  • Thank you received: 16
Hi there

Need some help here ! on Jem 3.0.7

I know, you don’t provide help for jem 3 but I can’t found a solution by myself…. So, please, be kind.
My site xevent.it have a complex link structure, necessary for to filter and to render the events in all the Italian’s regions and states (provinces).
The main link call an article that contain only jem modules from where it possible to choose to go in another main page (state) that also contain only modules or to go to a category article page that contain only modules too, in the category page there is a link to a jem simplelist, filtered by state and category.
Please visit the site (xevent.it) for better understanding.
Every module has an item ID assigned and simplelist is the only core jem link that I use.

So the link generated on the event view can be, for example:
/region-main/regionmain/event/id:event-name -> if the event is linked from a module in the region page
/state-main/statemain/event/id:event-name -> if the event is linked from a module in the state page
etc. etc. (depend from which page is called the event view)
Following the links on the site all work fine and the links are as expected;
Eg( from the main region page ) xevent.it/lombardia-main/lombardiamain/e...16:sting-in-concerto
But, on search from the joomla search field (via jem search plugin)
The link take the first valid article menu item and became:
“Veneto-main” is the link to the article id=1 ……… (the link work but the event is rendered in the wrong page: “Veneto” instead of “Lombardia”).

The WORST is that the same issue happen also in Google indexing and this is very bad.

So, my question is: how to fix the link construction for to have the right link?
I tried to found a solution, by myself, and the problem, I think, is in the getEventRoute function but I have no idea how to modify it and how it work !

What I done:
1 - I replaced the route.php file with the jem 2.1.6 route.php file: (with this the link became clean without any item menu)
2 - I created a new function inside the route.php : (for to assign the search page item id )
public static function getEventSearchRoute($id){
$link = 'index.php?option=com_jem&view=event&id='. $id.'&Itemid=957';
return $link;}
3 - I changed the function call in the jem search plugin with this new one.
Now the link is like this: xevent.it/component/jem/event/216-sting-in-concerto?Itemid=957
957 is the id of the search page.
this only stem the wrong link construction and the event is rendered in the search page, but the link appear a little freak and the view is still in the wrong place :(
Hope someone can give me same hints to solve this.

Thanks in advance

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Time to create page: 0.346 seconds


If you find JEM useful and if you use it on your site, please consider a donation to the project.

Private Messages

You are not logged in.

Follow us......