How to redirect my .com/blog to my server folder /blog ?
-
Hello SEO Moz !
Always hard to post something serious for the 04.01 but anyway let's try !
I'm releasing Joomla websites website.com, website.com/fr, website.com/es and so on.
Usually i have the following folders on my server
- [ROOT]/com
- [ROOT]/com/fr
- [ROOT]/com/es
However I would like to get the following now (for back up and security purpose).
- [ROOT]/com
- [ROOT]/es
- [ROOT]/fr
So now what can I do (I gues .htaccess) to open the folder [ROOT]/es when people clic on website.com/es ?
It sounds stupid but I really don't know.
I found this on internet but did not answer my needs.
.htaccess
RewriteEngine On
RewriteCond %{REQUEST_URI} !(^/fr/.) [NC]
RewriteRule ^(.)$ /sites/fr/$1 [L,R=301]Tks a lot !
Florian
-
Nop I just put all of them in the same folder but I would like to change it
-
Hi Flo - Were you able to resolve this issue?
-
Hello !
Tks you for your help ! I contacted them and now waiting for their answer.
Let see what we can do
Tks a lot
-
somewhere on your root folder you will have a .htaccess file
.htaccess is a small server file that you can put conditions in. some conditions will redirect to a "new" location (your new folders) when the .htaccess detects a url to an "old" location. this is commonly called "mod rewrite".
the software used to issue these commands varies based on your web site host. contact them and ask them what rewrite/redirection software is on your account (for example, one common one is ISAPI rewrite:
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
cross canonicalization with redirect
I'm working with a website that has turned one of its pages into its own website within the main website - mostly for the ease of customers, making it simpler to access that page using www.page.com rather than www.mainsite.com/about/page.
Technical SEO | | Shrine.SEO.Gal
As a result, there are two urls for that page (the ones just mentioned), both pointing to the exact same page, but with different urls. Now, they have made it so www.mainsite.com/about/page permanently redirects to www.page.com. which I thought was a good call. However, what do I do about canonicalization? Is it good to point the canonicalization of www.page.com to www.mainsite.com/about/page so that the rankings and link equity are maintained in the main website? Or would the fact that the www.mainsite.com/about/page redirects to www.page.com mess that up? I hope this makes sense!0 -
Can i do 301 redirect
So this is what im doing, 301 redirect to my site/allen-webdesign points to main domain Allen is the city i have a page called local-webdesign with all the cities. Will this improve my ranking or should i stop?
Technical SEO | | jsdfw0 -
301 Redirects
Hi, I have switched my site from a http .co.uk site to a https .com site. I have set a 301 redirect in the .htaccess file pointing all traffic going to the original .co.uk site to go to the new https: RewriteEngine on
Technical SEO | | imoprojects
RewriteCond %{HTTP_HOST} ^up-bus.co.uk$ [OR]
RewriteCond %{HTTP_HOST} ^www.up-bus.co.uk$
RewriteRule ^(.*)$ "https://www.up-bus.com/$1" [R=301,L] however when i search in google for keywords the original .co.uk site is still registering in search, is there something else I am required to do to tell google to use the new https site instead? Do i need to do redirects for every page, or is what I have done above sufficient? Hope you can help, I am struggling with getting our site to register on google search, any advice greatly welcome Thanks in advance, Ian0 -
Is there a tool to see all redirects?
I'm thinking this is a silly question, but I've never had to deal with it I thought I'd ask. Ok is there a tool out there that will show all the redirects to a domain. I'm working on a project that I keep stumbling on urls that redirect to the site I'm studying. They don't show up in Open Site or ahrefs as linking domains, but they keep popping up on me. Any thoughts?
Technical SEO | | BCutrer0 -
URL redirect question
Hi all, Just wondering whether anybody has experience of CMSs that do a double redirect and what affect that has on rankings. here's the example /page.htm is 301 redirected to /page.html which is 301 redirected to /page As Google has stated that 301 redirects pass on benefits to the new page, would a double redirect do the same? Looking forward to hearing your views.
Technical SEO | | A_Q0 -
Cgi-bin folder
Is there cg-bin folder of any site related to SEO in anyways and why we always block Cgi-bin folder in robots.txt.
Technical SEO | | Alick3000 -
Holy Redirects
Currently working on a project for a medium sized site (http://sleeponcall.com/) but the SEOMoz crawl crawled over 14,000 pages because the report is showing more than 8,000 redirects. The client has no clue how this happened as their previous web programmers may not have been on the ball. What could be causing the problem and what is the best way to untangle this mess?
Technical SEO | | Nobody15330770827560 -
Proxy servers and SEO
I read somewhere that reverse proxys can cause issue for search engines. Our server is using SQUID. What potential issues there might be?
Technical SEO | | Jani1