Jump to content

Install prestashop in a subdomain


Recommended Posts

Hi!

 

I'm installing Prestashop in a remote shared hosting where i have configured a only main domain name 'domainname.es'. And i would like to accesss to the prestashop e-shop via 'shop.domainname.es'.

 

I've configured a folder /tienda as shop.domainname.es via cpanel and i've copied the content of the prestashop folder into this folder.

 

I have two .htaccess, one in the / (root) and another one in /shop,

 

How would i have to configure it in order to access to shop.domainname.es?

 

The content of these files is the next:

 

.htaccess of the / (root):

RewriteCond %{HTTP_HOST} !^(www.)?domainname.es$ [NC]
RewriteCond %{HTTP_HOST} ^(www.)?shop.domainname.es$ [NC]
RewriteCond %{REQUEST_URI} !^/shop/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /shop/$1
RewriteCond %{HTTP_HOST} ^(www.)?shop.domainname.es$ [NC]
RewriteRule ^(/)?$ shop/ [L]

.htaccess de /shop:

RewriteEngine on
RewriteCond %{HTTP_HOST} ^shop\.domainname\.es$ [OR]
RewriteCond %{HTTP_HOST} ^www\.shop\.domainname\.es$
RewriteRule ^/?$ "http\:\/\/shop\.domainname\.es" [R=301,L]

Best regards

Edited by jgc412 (see edit history)
Link to comment
Share on other sites

you need to contact your hosting provider and ask them for support in creating a subdomain on your hosting account.  do that first and make sure it works properly using a test html or txt file, confirm that you can reach the test file from a browser.

 

then you can install prestashop using the subdomain

Link to comment
Share on other sites

php is disabled for this subdomain probably and the result is not possible to open any kind of .php file

optionally, in .htaccess file you've got

php_flag engine off

if so, change it to

php_flag engine on

or remove it completly

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...