.htaccess file can't be replaced to change URLs
-
Went from a static site to dynamic using wordpress after transferring the site from a different server to the current one I needed to upload an .htaccess file to keep google page rankings for search engines and tell crawlers of this 301 redirect. Because the new web server is on UNIX so the format to do this is like this:
redirectMatch 301^(.*)$ https://www.mysite.com/index.html/
redirectMatch permanent ^(.*)$ https://www.mysite.com/I noticed the site is also just using https:// without the WWW. and
we wanted it with the www.Anyway when I uploaded my htaccess.txt file with all the old urls and new urls to redirect took out the .txt (.htaccess) there was already another .htaccess file there?
with this in the file:# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPressI tried to replace it because it’s really important that we keep our pagerank, and the site was disabled “page error” I had to put the origninal .htaccess file that was there. I even thought if I combined the two codes it would work and same thing the site didn’t work?
How can I include my 301 redirect with this other file that was put there mysteriously?
- The topic ‘.htaccess file can't be replaced to change URLs’ is closed to new replies.