I want to create secondary website to be accessed in a subfolder. My base magento installation folder is in domain's root http://mydomain.com/. I am setting up secondary website in http://mydomain.com/ws2/.

I have created the secondary website in Magento Admin, given the code ws2 and set unsecure and secure base urls to http://mydomain.com/ws2/.

Since I am on a shared hosting, and I don't have access to apache configuration, I have followed this tutorial with Step 2- Method 1 Separate Directories for Each Store.

Essentially, I have created a new folder, copied there index.php and .htaccess. I have created the symlinks pointing at the app, include, js, lib, media, skin, var folders of the root installation.

I have edited index.php in ws2 folder, changing last line to:

Mage::run('ws2', 'website');

Unfortunately, when I access the url http://mydomain.com/ws2/, I get 404 Page Not Found error.

Have I made a big mistake? If no, how can I debug this?

  • Is that magento's or servers 404 error? – oleksii.svarychevskyi Feb 2 '14 at 12:17
  • if you place a test .html file (lets call it test.html) in the /ws2/ folder, can you load it with mydomain.com/ws2/test.html? – ProxiBlue Feb 2 '14 at 12:25
  • @ProxiBlue yes, I can load a test html file – perissf Feb 2 '14 at 12:49

If 404 Error is generated by Magento, it means that everything is fine.

Just magento's home page is cms page and by default is configured to be displayed on default website.

Go to admin section to CMS->Pages and edit "Home" page to be displayed on all websites. Or create one more home page which will be displayed only on your new website.

| improve this answer | |
  • Thanks for your answer. It's a Magento-generated 404 error. The home page is mapped to the store view of the default store of the new website. The default store of the new website is also linked to the root category of the main website. I'll check with the template vendor if it's a template issue – perissf Feb 2 '14 at 12:59
  • 1
    Solved! The issue was caused by the store view that was disabled. – perissf Feb 2 '14 at 13:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.