cancel
Showing results for 
Search instead for 
Did you mean: 

Broken links after moving to new folder

Broken links after moving to new folder

Hi everyone!

 

I just moved all my magento files (with hidden files like htaccess etc) to a subfolder named "2017".

> I checked the secure and unsecure URL and added /2017/

> deleted the cache folder

 

The site and the admin console are visible but

 

1 > when i click on a link, it doesn't work

2 > some images are broken

 

I assume that it's a htaccess problem but i'm not easy with this code.

Any help would be much appreciated Smiley Happy)

 

Regards

Miran

9 REPLIES 9

Re: Broken links after moving to new folder

Hi @lemiran,

 

I'm nto sure but I remember that there is a /magento/ path inside the htaccess as an example of using Magento inside a folder.

 

For example, on Magento 1.9.3.1, the htaccess has this lines (from line 117 to 126):

 

    RewriteEngine on

############################################
## you can put here your magento root folder
## path relative to web root

    #RewriteBase /magento/

############################################
## uncomment next line to enable light API calls processing

Maybe you can change this part:

 

    RewriteEngine on

############################################
## you can put here your magento root folder
## path relative to web root

    RewriteBase /2017/

############################################
## uncomment next line to enable light API calls processing

Re: Broken links after moving to new folder

Hi Damian and thank you for your help!

Unfortunately i already saw this and modified as you mentioned it /2017/ and uncommented the line...

 

Regards

Miran

Re: Broken links after moving to new folder

@lemiran,

 

Can you share the old link, the new url and the link with the actual problem (as example)?

Re: Broken links after moving to new folder

HI again Damian!

 

Here is the old URL (the root of my hosting)

http://laboitedevin.com/

 

I moved all the files in a subfolder :  http://laboitedevin.com/2017/ (this link actually works)

But the menu links don't work anymore and point to the old root: http://laboitedevin.com/vins-rouges/bordeaux.html

 

it must be http://laboitedevin.com/2017/vins-rouges/bordeaux.html

 

Thank you!

Miran

Re: Broken links after moving to new folder

I was able to navegate to http://laboitedevin.com/2017/champagnes/gosset.html

After that I've visited a product and then I've added a product to the cart and everything works fine.

 

The problem is the menu.

 

  • Can you delete the Magento cache?
  • Is it possible that the menu was build using a Static Block instead the original block?
  • Is there a 3rd-party module that overrides the topmenu block?

I'm pretty sure that you've followed the right steps but there is a module or a block there with the old URL.

Re: Broken links after moving to new folder

Good Morning Damian

 

Thank you very very much Smiley Happy

I'm not the one who created the site, the old webmaster gone so i have to take the magento system on my own...

 

So how could i verify these things?

 

> i already deleted the cache and session folders, and deactivated the cache system (system > cache management > tick all the boxes and deactivate. But the both cache and session folders recreate themselves over and over again, it's a bit weird no?

 

> I just don't understand (because i have a very little knowledge on the Magento system) what a Static Block. How could i check this?

 

> The 3rd party module : how could i verify this?

 

I will take a glance on this, but if you could tell me how to check these things it would be great!!

Regards

 

Miran

Re: Broken links after moving to new folder

I found this (cms > static blocks)

I assume that we can check it here?

 

And i found the catalog > my categories and checked out there the links to my pages...

 

Static Blocks

 

Here is the screen print for the "vins rouges" page

 

Vins Rouges page

 

Re: Broken links after moving to new folder

Goodmorning @Damian Culotta!

 

Did you see my screenprints? Is this helping you to understand my problem?

Thank you very much!

 

Miran

Re: Broken links after moving to new folder

I guess that your menu is inside one of those blocks but you need to check the content to be sure.

If you find the menu, you need to change the old domain with the new sotre url (or you can use the store_url varible)