Laurent_C1
New Pleskian
SERVER : centOs with Plesk 11.5 - domain use wildcard via a dns config A and wilcard in DNS
1. I install wordpress and theme with multisite option.
2. I config it to use subdomain
3. its ok with wordpress but no subdomain created on the server.
Question : Someone know how to config plesk 11.5_64 and server to allow dynamic subdomain like myblog.mydomaon.com ?
Note : I fallow the tuto from wordpress :
/var/www/vhosts/domain.com/conf/ create or edit a vhost.conf file.
Add a single line - ServerAlias *.yourdomain.com - to the start of the file.
Note, for Plesk 10 you may find you need
Add a single line - ServerAlias "*.yourdomain.com" - to the start of the file.
Do not add the <ServerName> or <VirtualHost> headers - just add the server alias command and wildcard domain name on a single line as shown above.
Author's note - On my install, being a belt and braces type of guy, I also added these lines (without line numbers) after the ServerAlias line:
<Directory /var/www/vhosts/mydomain.com/>
AllowOverride FileInfo Options
php_admin_flag safe_mode off
</Directory>
Save the vhost.conf file and restart Apache again (as above).
That sets up the server to read the wildcard subdomain names, and point the page requests to the WordPress installation's root folder with its htaccess file, for resolving to the correct home or sub-site / sub-blog.
But, in order to get there, the DNS wildcard still has to be set - the standard WordPress instructions work fine for this too -
Got to your Domain page in Plesk - choose DNS settings - add a record
Add a CNAME entry using *.example.com CNAME example.com as the parameters.
Check the wildcard subdomain shows in the DNS list (probably as the top entry) and update DNS using the update button
Note - if you add the DNS record as an A record ( *.example.com in A xxx.xxx.xxx.xxx ) you might get some delays in resolving blog addresses initially. Using the CNAME entry in testing proved less troublesome. Your experience may differ.
On Plesk 11 I had to run this shell command as root in order to rebuild the vhosts config http://forum.parallels.com/showthread.php?t=260504 (Post #4):
Thank you
1. I install wordpress and theme with multisite option.
2. I config it to use subdomain
3. its ok with wordpress but no subdomain created on the server.
Question : Someone know how to config plesk 11.5_64 and server to allow dynamic subdomain like myblog.mydomaon.com ?
Note : I fallow the tuto from wordpress :
/var/www/vhosts/domain.com/conf/ create or edit a vhost.conf file.
Add a single line - ServerAlias *.yourdomain.com - to the start of the file.
Note, for Plesk 10 you may find you need
Add a single line - ServerAlias "*.yourdomain.com" - to the start of the file.
Do not add the <ServerName> or <VirtualHost> headers - just add the server alias command and wildcard domain name on a single line as shown above.
Author's note - On my install, being a belt and braces type of guy, I also added these lines (without line numbers) after the ServerAlias line:
<Directory /var/www/vhosts/mydomain.com/>
AllowOverride FileInfo Options
php_admin_flag safe_mode off
</Directory>
Save the vhost.conf file and restart Apache again (as above).
That sets up the server to read the wildcard subdomain names, and point the page requests to the WordPress installation's root folder with its htaccess file, for resolving to the correct home or sub-site / sub-blog.
But, in order to get there, the DNS wildcard still has to be set - the standard WordPress instructions work fine for this too -
Got to your Domain page in Plesk - choose DNS settings - add a record
Add a CNAME entry using *.example.com CNAME example.com as the parameters.
Check the wildcard subdomain shows in the DNS list (probably as the top entry) and update DNS using the update button
Note - if you add the DNS record as an A record ( *.example.com in A xxx.xxx.xxx.xxx ) you might get some delays in resolving blog addresses initially. Using the CNAME entry in testing proved less troublesome. Your experience may differ.
On Plesk 11 I had to run this shell command as root in order to rebuild the vhosts config http://forum.parallels.com/showthread.php?t=260504 (Post #4):
Thank you