Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken channel link in Tagged Items RSS feed #18249

Closed
dBarboni opened this issue Oct 5, 2017 · 12 comments
Closed

Broken channel link in Tagged Items RSS feed #18249

dBarboni opened this issue Oct 5, 2017 · 12 comments

Comments

@dBarboni
Copy link

dBarboni commented Oct 5, 2017

Steps to reproduce the issue

  1. Create an article. Give it a Tag.
  2. Create a menu item of type Tags->Tagged Items. Select the tag you added in step 1.
  3. Navigate to your new menu item and add ?format=feed&type=rss to the end of the URL to view the RSS feed.
  4. Look at the value of the channel->link element. Note that "/Array" has been added to the URL. The channel link results in a 404 if accessed.

Expected result

The link should point back to your menu item.

Actual result

The link points back to the menu item but with "/Array" appended to the URL.

System information (as much as possible)

Joomla 3.8.1
PHP 5.6.31

Additional comments

Occurs on a clean install of 3.8.1.

@brianteeman
Copy link
Contributor

I can confirm this

@EmilMassey
Copy link
Contributor

EmilMassey commented Oct 27, 2017

Tagged items' links are incorrect too. They point to 404 page. For example when site's default view is the category, the link looks like: http://example.com/?id=218:some-alias.

The problem is in the way we create link to an item in tag model. For com_content this won't work, because the router (legacy, I didn't check the new advanced router) requires catid parameter and we don't know article's category ID.

$explodedTypeAlias = explode('.', $item->type_alias);
$item->link = 'index.php?option=' . $explodedTypeAlias[0] . '&view=' . $explodedTypeAlias[1] . '&id='
. $item->content_item_id . ':' . $item->core_alias;

As the Tags Component is supposed to work with any component, it is not possible to create link the same way for every item type. I think we should somehow allow developers to implement their own method to create items' links.

At the moment, tag feed is broken and useless. :( I hope we'll fix this ASAP, because this functionality is quite important on website I develop.

@ghost
Copy link

ghost commented Oct 27, 2017

@EmilMassey can you provide a Pull Request so we can Test and fix ASAP?

@EmilMassey
Copy link
Contributor

@franz-wohlkoenig Unfortunately, right now I don't even know where to begin. To be honest this is the first time I saw Tag Component's code and I need some time to get to know it before I change anything in it.

@alschaeffer
Copy link

I have the same problem. I don't understand, why you have to edit the category in the link.

Instead of
http://example.com/?id=218:some-alias
this link would work for me
http://example.com/218-some-alias

@SharkyKZ
Copy link
Contributor

@EmilMassey @alschaeffer for your issue see #20723.

@joomla-cms-bot
Copy link

Set to "closed" on behalf of @franz-wohlkoenig by The JTracker Application at issues.joomla.org/joomla-cms/18249

@ghost
Copy link

ghost commented Jun 12, 2018

closed as having Pull Request #20723

@SharkyKZ
Copy link
Contributor

@franz-wohlkoenig reopen this please. #20723 only solves the issue described in the comments.

@joomla-cms-bot
Copy link

Set to "open" on behalf of @franz-wohlkoenig by The JTracker Application at issues.joomla.org/joomla-cms/18249

@ghost
Copy link

ghost commented Jun 12, 2018

Reopened as stated above.

@wilsonge
Copy link
Contributor

Closed as we have a PR with #21690

mbabker pushed a commit that referenced this issue Sep 3, 2018
* Fix tags RSS feed. Fixes #18249

* Fix PHPCS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants