Jump to content

URL structure changed, what to put in .htaccess generator box


Recommended Posts

I've just launched a new site on PrestaShop

 

It replaces an older site that was just written in static HTML.

 

In order to preserve link juice as much as possible I want to do the following

 

Redirect

 

www.mysite.com/index_files/.......

 

to

 

www.mysite.com/ja/

 

AND

 

www.mysite.com/eng/......

 

to

 

www.mysite.com/en/.....

 

 

 

How should I write those redirect instructions.

Please be EXPLICIT as possible.

i.e. to I need to write "Redirect" above or before the instructions?

Link to comment
Share on other sites

I've just launched a new site on PrestaShop

 

It replaces an older site that was just written in static HTML.

 

In order to preserve link juice as much as possible I want to do the following

 

Redirect

 

www.mysite.com/index_files/.......

 

to

 

www.mysite.com/ja/

 

AND

 

www.mysite.com/eng/......

 

to

 

www.mysite.com/en/.....

 

 

 

How should I write those redirect instructions.

Please be EXPLICIT as possible.

i.e. to I need to write "Redirect" above or before the instructions?

 

You need to write some rules for Apache's rewrite module. Google for 'apache mod rewrite tutorial' and you'll find more than enough to help you out. An example: http://www.sitepoint.com/guide-url-rewriting/

Link to comment
Share on other sites

This is what I mean about being EXPLICIT.

 

Do I need to write all of this?

<IfModule mod_rewrite.c>

RewriteEngine on

RewriteRule ^/shortcut$ /complicated/and/way/too/long/url/here

</IfModule>

 

or just the 2nd and 3rd line?

 

or just the 3rd line?

 

 

Little help?

Link to comment
Share on other sites

This is what I mean about being EXPLICIT.

 

Do I need to write all of this?

<IfModule mod_rewrite.c>

RewriteEngine on

RewriteRule ^/shortcut$ /complicated/and/way/too/long/url/here

</IfModule>

 

or just the 2nd and 3rd line?

 

or just the 3rd line?

 

 

Little help?

 

Well, I could do everything for you but then I'll have to send you an invoice for it. Sometimes you just have to figure stuff out yourself, if you don't have the time you pay people to do it for you.

 

All those lines should be fine. The IfModule statement is just a safety statement in case the rewrite module isn't enabled.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...