× Here you can get community support related to ReDJ.

how to redirect this kind of article ID sef url?

  • skyfranky
  • Topic Author
  • Offline
  • New Member
  • New Member
More
7 years 3 months ago #5875 by skyfranky
I found that I can display a joomla article with the shortest link by just include the article ID in the website url like below:

here is a joomla.org article with id 3092
community.joomla.org/gsoc-2017/3092-call-for-ideas-google-summer-of-code-with-joomla-2017.html

you can call the same article with this link:
community.joomla.org/3092

so I created so many such urls, and get them printed. suddenly all such url got 404 error, and I could not find out why. now I want to setup one redirect for all url request with format like www.mysite.com/article_ID to the normal one that the article can be shown without error.

Can you kindly tell me if this is possible? what is the setting?
www.mysite.com/article_ID?tmpl=component
redirect to
www.mysite.com/index.php?option=com_content&view=article&id=article_ID?tmpl=component

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

More
7 years 3 months ago - 7 years 3 months ago #5879 by admin
Hi.

www.mysite.com/article_ID?tmpl=component
redirect to
www.mysite.com/index.php?option=com_content&view=article&id=article_ID?tmpl=component


Create a rule as follow:
From URL: ^/[0-9]+\?tmpl=component$
To URL: {scheme}://{siteurl}/index.php?option=com_content&view=article&id={pathltrim /}?tmpl=component
Request only: true (checked)

In case you have ReDJ Enterprise, you can also select the "internal redirect (200)" for the rule, so your users will stay on the short path.

Kind regards,
Luigi
Last edit: 7 years 3 months ago by admin.

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

  • skyfranky
  • Topic Author
  • Offline
  • New Member
  • New Member
More
6 years 8 months ago #6247 by skyfranky
Replied by skyfranky on topic how to redirect this kind of article ID sef url?
Hi

sorry fo the late reply. I added to redirect as you suggested, but it is not working
www.screencast.com/t/8fvRev5zEiKO

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

More
6 years 7 months ago #6257 by admin
Hi and sorry for delay.
The rule seems correct, but I cannot verify it. Can you post the test URL here or send me an email at info(at)selfget.com?

Kind regards,
Luigi

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

Time to create page: 0.106 seconds