Hello,
Tu peux utiliser le même tutoriel, en changeant quelques options (pas testé);
A la place de
key | value
http_host | www.thesearchgoeson.com
site_url | http://www.thesearchgoeson.com
base_url | /
site_name | MODxCMS TheSearchGoesOn test
site_start | 6
error_page | 7 [optional, aber empfehlenswert]
default_template | 3 [optional, wenn Sie mehrere templates vorbereitet haben
il faudrait mettre quelque chose du genre:
key | value
http_host | http://localhost/modx/site2
site_url | http://localhost/modx/site2
base_url | D:\Wamp\www\modx\site2\
site_name | MODxCMS TheSearchGoesOn test
site_start | 6
error_page | 7 [optional, aber empfehlenswert]
default_template | 3 [optional, wenn Sie mehrere templates vorbereitet haben
Puis à la place de:
/* setup for multiple domains */
switch(strtolower(MODX_HTTP_HOST)) {
case 'www.modx-templates.com:80':
case 'www.modx-templates.com':
// if the http_host is modx-templates.com, switch the context to web
$modx->initialize('web');
break;
case 'www.ffmwireless.de:80':
case 'www.ffmwireless.de':
// if the http_host is ffmwireless.de, switch the context to ffmwireless
$modx->initialize('ffmwireless');
break;
case 'www.thesearchgoeson.com:80':
case 'www.thesearchgoeson.com':
// if the http_host is thesearchgoeson.com, switch the context to thesearch
$modx->initialize('thesearch');
break;
default:
// by default / if no other rule can be applied, load 'web' context
$modx->initialize('web');
break;
}
il faudrait mettre
/* setup for multiple domains */
switch(strtolower(MODX_HTTP_HOST)) {
case 'localhost/modx:80':
case 'localhost/modx':
// if the http_host is modx-templates.com, switch the context to web
$modx->initialize('web');
break;
case 'localhost/modx/site2:80':
case 'localhost/modx/site2':
// if the http_host is ffmwireless.de, switch the context to ffmwireless
$modx->initialize('site2');
break;
default:
// by default / if no other rule can be applied, load 'web' context
$modx->initialize('web');
break;
}
ou le dossier principal correspond au contexte ’web’ et le dossier site2 correspond au contexte ’site2’
Il faut également faire attention quel est le dossier http de base, je suis parti du principe que c’était le dossier ’www’ (modx étant un sous-dossier)
Edit: corrections car modx est installé dans le dossier ’modx’