By Randy Carey on Tuesday, 03 May 2022
Posted in Technical Issues
Replies 7
Likes 0
Views 534
Votes 0
We have our ES Groups in the menu item with the URL <root>/groups. It was reported that when one was within a group viewing the list of discussions, clicking on any given discussion was returning one to the page that lists all groups. Further, the "New Discussion" button was also taking one to the list of groups.

In these cases I saw the formed links duplicating groups/ within the url. For example, to create a new discussion the URL would look like <root>/en/groups/groups/257-healthnet/27-discussions/create . My solution, to get the pages working again, was to override the layout files and add code to capture the generated link and remove any redundant "groups/" before echoing the link to the anchor tag. All works when that duplicate "groups/" is removed from the link.
-- generated link that fails: <root>/en/groups/groups/257-healthnet/27-discussions/create
-- fixed link that works: <root>/en/groups/257-healthnet/27-discussions/create

My client does not want me to grant login access to their site, plus I have already fixed this problem through overrides, so the best I can do is report this issue with the detail I just provided. The errant link is being generated by the ES::router.
I hope you can understand our situation, it will be very difficult for us to know where goes wrong if we can't investigate this on the site directly because I can't replicate the issue locally.

May I know do you have installed any 3rd party SEF extension on the site (e.g. sh404sef)?

And the new menu item alias you set to "groups" as well?
·
Thursday, 05 May 2022 13:55
·
0 Likes
·
0 Votes
·
0 Comments
·
I certainly understand the challenge of investigating a bug report without being able to examine the site experienceing it. I still wanted to report it so someone cold be aware. ...as for me and this site, I have a fix in place.

We are not using any 3rd part SEF extensions. Usinbg a debugger, I walked through the code and saw the problem immediately after the router returned the URL.
·
Friday, 06 May 2022 00:24
·
0 Likes
·
0 Votes
·
0 Comments
·
Okay, can you provide us with some screenshots regarding your current Easysocial menu structure so we can try to replicate local and see whether we can reproduce this issue?

Is this issue only happen when you view the group discussion listing page?
·
Friday, 06 May 2022 10:07
·
0 Likes
·
0 Votes
·
0 Comments
·
I've attached a screenshot of the menu item for Groups. It belongs to our main menu, and Groups is a first-level menu item. So for someone viewing a group, the url pattern is <site>/en/groups/100-<group-name> ... the EasySocial router built the link be <site>/en/groups/groups/100-<group-name> ...(I don't recall if the ES router added the language tag, but the "en" is applied at some point.)

Note that this menu item is accessible only to a particular access level. We also use multiple languages, with "en" being the default. The site uses only Groups and Events from Easy Social, and does not use a menu item for the EasySocial Dashboard.
·
Friday, 06 May 2022 23:20
·
0 Likes
·
0 Votes
·
0 Comments
·
It seems like I still can't manage to replicate it, you can watch my attached video below and see if I reproduce this issue wrongly?

By the way, can you try to purge the SEF URLs from the backend > Easysocial > SEF URLs and see how it goes?

Because you have to purge this since you added the new Easysocial menu item, so the system needs to generate the final SEF URLs on the site.

Once you purge the SEF URLs, you have to access your site homepage so the Easysocial system will regenerate the final SEF URLs on the site.
·
Monday, 09 May 2022 12:09
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks for looking into this. I have a solution in place (for the client's site). They have had me apply alot of customization, and it is possible that there is some quirk in the way their menuing works. When I get the time, I will walk through the code with a debugger and see if I can see where the extra "/groups" is being added. If I see something worth reporting, I'll report it.
·
Saturday, 14 May 2022 05:45
·
0 Likes
·
0 Votes
·
0 Comments
·
Sure, keep us update then.
·
Tuesday, 17 May 2022 13:38
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post