Multiple Custom Admin URL - magento

im trying to have the same backend but with multiple subdomains. first i created one of my subdomains in the backend has showen in this image above.
And is working fine, but not i need the same backend with another subdomain for example "sync.mydomain.com", but i cant find any information on magento docs in configuring custom admin url in multiple domains. Does someone have any idea if it is possible to configure it on magento?

In order to make magento work with multiple domains, you need to make few steps.
System->Manage Stores -> Create Store Fill in the store fields,
taking care that the Website and Root Category are the same as your
primary site.store. Save Store
Create Store View Fill in the store view fields, change Store to the
new store you just created, give your store view a Name (spaces ok),
a code and make sure it’s enabled, after that save the store view.
System->Configuration->Web Change the scope on the upper left to your newly created store view
Change Unsecure->Base URL to your second domain (You’ll have to uncheck Use Website)
Change Secure->Base URL to your second domain (You’ll have to uncheck Use Website)
Save Config
Open the .htaccess at the root of your Magento install
Add the following, obviously changing the values with your own:
SetEnvIf Host www.mysecondarydomain.com MAGE_RUN_CODE=yoursecondarystoreviewcode
SetEnvIf Host ^mysecondarydomain.com MAGE_RUN_CODE=yoursecondarystoreviewcode
Clear the cache and re-index the site.
Here is the article for more information:
http://madproject.com/programming/magento-one-site-multiple-domains/

Related

Create url rewrites automatically for store view which is created programmatically

When new store view is created from magento admin backend, all url rewrites for that store view are created automatically. But when I create programmatically store view from frontend, it's been created but without url rewrites, so basically I will need to create all url rewrites manually but it's impossible since there where about 3000 of them.
I cant find piece of code where magento created those url rewrites automatically after store view is created from admin backend.
The url generation for catalog happens here:
https://github.com/magento/magento2/blob/7aa94564d85e408baea01abc5315a0441401c375/app/code/Magento/CatalogUrlRewrite/etc/adminhtml/di.xml#L10
and I assume that this plugin just not dispatched in your case, since you are creating store view from frontend scope

Magento categories as subdomain

Is it possible to create urls for category as subdomain, for example now it is:
mystore.com/category
I would like it to be
category.mystore.com
I know there is multistore option, so I could create more websites and set root directory for every category, but there would be problem with cart sharing, next thing is site is has 2 languages - so I'm using multi store for site translation
There's no way to achieve this out of the box, but this can be done using a custom router. Create a custom router and insert it before the standard router. In your custom router, check the subdomain of the request. If it matches a category URL key (or whatever other criteria you'd like to use), rewrite the request to that of a standard category page (i.e. /catalog/category/view/id/123/). Keep in mind that your users will probably leave the subdomain when they click on a link because your base URL will not include the category-specific subdomain. Take a look at Mage_Cms_Controller_Router as an example of a custom router.

Change Magento from multiple stores with multiple domains to multiple stores on one domain

I currently have 3 magento stores, each has its own domain name. (just the ltd is different)
I want to change this so that I just have one tld, the .com. But I want to keep the seperate stores.
How can I change this back? Do I simply just remove the code from the index.php file, and change it in config?
Can be done from Admin
Go to Magento Admin
Navigate to System -> Manage Store. There you will see all your websites, stores and store view.
You'll your stores in second column. Click on them and change Website (top row)
Save
Good luck!

How to set the default store (___store) with Magento, excluding front/home page

My current Magento website is requesting a store (via lightbox) when the user first arrives on the home page. The user will continue navigating the website and content will appear properly without any issues.
The problem is when they arrive on a sub-page of the website and the store has not been set previously by the user. This also impacts SEO.
Question: How do I set the default store, without affecting the lightbox that is appearing on the home page.
From the comments traded back and forth, it sounds like your default store isn't set properly. If you aren't using any index.php hacks to do with store view setting, you should be able to follow the following steps to resolve this:
Magento: Setting the default homepage / store when you have multiple stores

Have Magento respond to several domains with the same store

I would like to have my magento install respond to two different domains, e.g.
a.mydomain.com and
b.anotherdomain.com
I need magento to respond with the same store, showing the same customers, the same catalog, same prices, etc.
The difference, of course, is that when the store is accessed through a.mydomain.com all the links and urls should use this domain as baseurl, and when it is accessed through b.anotherdomain.com all links and urls should use b.anotherdomain.com as baseurl.
Is there any way to do so? All the documentation I've found so far deal with having different stores on the same magento instance, while what I need here is to have the same store respond to two different URLs.
Thank you!
Everything I know of Magento says it was designed to prevent exactly this from happening so as not to be penalised by search engines for duplicate content.
You can, however, have multiple stores that share customers and catalog and products and prices and so on, but represent a separate domain each. In System > Manage Stores add several Stores for a single website and use the same root category for them all. Then in System > Configuration > Web assign the various domains.
easy enough, just set them both to use the same store code (or just default)
have a look in index.php
you can set the $mageRunCode to be whatever you want, you don't have to use the server environment variables method they have there, look at earlier versions of Magento to see the index.php file there.
see this old article of ours
http://www.edmondscommerce.co.uk/magento/magento-multistore-setup-in-a-nutshell/

Resources