Ridirezionare URL con /component/content/article e
-
Lucc
-
Topic Author
-
Offline
-
New Member
-
Less
More
-
Posts: 4
-
Thank you received: 0
-
-
Less
More
-
Posts: 3194
-
Thank you received: 441
-
-
10 years 3 weeks ago #3728
by admin
Hi,
you can create two rules as follow:
From URL: ^/component/content/article\.html\?id=30$
To URL: {scheme}://{siteurl}/30-articolo.html
Request only: true (checked)
And:
From URL: ^/index\.php\?option=com_content&view=article&id=30$
To URL: {scheme}://{siteurl}/30-articolo.html
Request only: true (checked)
Please, post your question in english (this forum is english only).
Kind regards
The following user(s) said Thank You: Lucc
Please Log in or Create an account to join the conversation.
-
Lucc
-
Topic Author
-
Offline
-
New Member
-
Less
More
-
Posts: 4
-
Thank you received: 0
-
-
10 years 3 weeks ago #3730
by Lucc
Thank you.
just for "learning purposes" I'd like to know the equivalent Redirect 301 syntax, if you can tell me.
Kind regards
Please Log in or Create an account to join the conversation.
Less
More
-
Posts: 3194
-
Thank you received: 441
-
-
10 years 3 weeks ago #3731
by admin
I guess you mean .htaccess redirection. If so there are some options, the simplest one is to use mod_alias (you have simple URLs so there's no need to use regular expressions or mod_rewrite). This should work:
Redirect permanent /component/content/article.html?id=30 http://www.miosito.com/30-articolo.html
Best regards
Please Log in or Create an account to join the conversation.
-
Lucc
-
Topic Author
-
Offline
-
New Member
-
Less
More
-
Posts: 4
-
Thank you received: 0
-
-
10 years 3 weeks ago #3732
by Lucc
hi, unfortunately it's not working. I've checked many times in order to see if I made any synthax error but I didn't
Please Log in or Create an account to join the conversation.
Less
More
-
Posts: 3194
-
Thank you received: 441
-
-
10 years 3 weeks ago #3735
by admin
Hi,
the problem could be the query string, so try this (it works on my env):
RewriteEngine On
RewriteCond %{QUERY_STRING} id=30
RewriteCond %{REQUEST_URI} /component/content/article.html
RewriteRule ^(.*)$ http://www.miosito.com/30-articolo.html [L]
Kind regards,
Luigi
Please Log in or Create an account to join the conversation.
Time to create page: 0.137 seconds