I need add /movimento in all urls /item*
http://mareconteudo.com.br/item/o-que-vimos-no-content-marketing-world-copy-copy
i need:
http://mareconteudo.com.br/movimento/item/o-que-vimos-no-content-marketing-world-copy-copy
Same help me?
Try the following
RewriteEngine On
RewriteRule ^/?item/ /movimento%{REQUEST_URI} [R,L]
Related
Please help me on the RewriteRule below. I want to show the v3.php file for https://example.org/signup.
# Turn Rewrite Engine On
RewriteEngine on
# Rewrite for signup
RewriteRule ^signup v3.php [NC,L]
Works. But all other requests after /signup like /signups or https://example.org/signup/example/whatever show the v3.php as well. I need that RewriteRule only for that exact folder name.
Thanks for your help!
RewriteRule ^signup/?$ v3.php [NC,L]
Thank you, #anubhava
I currently goto:
support-requests/?st_id=7
Ideally i would like to just go straight here using .htaccess url-rewriting to make the page neater to look at and navigate to without the "?st_id=" being displayed in the url.
support-requests/7
This is what i currently have but i know its wrong and it does not work:
RewriteCond %{QUERY_STRING} ^(\w+)=(\w+)$
RewriteRule support-requests/ support-requests/%1/%2/?
Could i have some assistance in getting this correct please?
Thanks
Use this:
RewriteEngine On
RewriteRule ^support-requests/([^/]*)$ /support-requests/?st_id=$1 [L]
Should leave you with:
www.example.com/support-requests/7
I am in need of a URL rewrite to http://jzbeta.local/category.php?u=new-page&limit=all&page=2&style=new as below,
http://jzbeta.local/new-page&limit=all&page=2&style=new
So far my htaccess file has the following rule:
RewriteRule ^([a-zA-Z0-9\-]+)\/?$ /category.php?u=$1 [NC]
Where I can use only one query string.
Any help is greatly appreciated.
UPDATE
Once i changed existing rewrite as following, it worked as i expected.
RewriteRule ^([a-zA-Z0-9\-]+)\/?$ /category.php?u=$1 **[L,QSA]**
Thanks for the suggestions.
You can use the following rule :
RewriteRule ^([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$ /category.php?u=$1&limit=$2&page=$3&style=$4 [NC,L]
I have the following htaccess rules but I dont know how to make it work:
RewriteEngine on
RewriteRule ^game/([^/]*)$ index.php?cash=$1
The following is the screen shot of my folders structure:
Can someone tell me how to get it to work? I have also tried:
RewriteRule ^index.php([^/]*)$ index.php?cash=$1
The URL that I want to display is: http://localhost/biteep/game/100 while the URL that I want the browser to go to is http://localhost/biteep/game?cash=100
Try to put a rewrite base into your .htaccess:
RewriteBase /biteep/
And this route should be enough:
RewriteRule ^game\/(\d+)$ index.php?cash=$1
So it works when I do this
RewriteEngine on
RewriteRule ^([0-9]+)$ index.php?cash=$1
Usually is the other way aroud, but I need to redirect my static urls to dynamic ones as a variable part of the first one.
I need to redirect:
http:/example.com/sub1/sub-2/2014147-test-page-45x.html
http:/example.com/sub1/sub-6/8014149-test-24page.html
http:/example.com/sub1/sub-25/7514157-58test-page.html
to
http://example.com/sub1/testing.php?s=2014147
http://example.com/sub1/testing.php?s=8014149
http://example.com/sub1/testing.php?s=7514157
I know I need to use %{REQUEST_URI}, but I can't put it together.
Any help will be appreciated.
Thanks.
Assuming your .htaccess is at root of example.com, adding following to it will do the trick.
RewriteEngine On
RewriteBase /
RewriteRule ^sub1/[^/]+/(\d+).*$ sub1/testing.php?s=$1 [R,L]
This should work:
RewriteEngine on
RewriteRule ^sub1/(.*)/([0-9]+)-(.*)$ /sub1/testing.php?s=$2 [R=301,L]