a-I use root.
b- This is the content of wp.conf:
For this configuration to work you’ll also need to have mod_rewrite
and mod_vhost_alias loaded and working in Apache.
To enable these modules run
a2enmod rewrite && a2enmod vhost_alias && /etc/init.d/apache2 restart
The above example is checked. Here are some _alternative_ suggestions:
## A defined Virtual host
NameVirtualHost *:80
<VirtualHost *:80>
ServerName blog.example.com
DocumentRoot /usr/share/wordpress/
DirectoryIndex index.php index.html
ErrorLog /var/log/apache2/wp-error.log
TransferLog /var/log/apache2/wp-access.log
# wp-content in /var/lib/wordpress/wp-content
Alias /wp-content /var/lib/wordpress/wp-content
<Directory /usr/share/wordpress>
Options FollowSymLinks
Order allow,deny
Allow from all
</Directory>
<Directory /var/lib/wordpress/wp-content>
Options FollowSymLinks
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
## Without using Virtual host, hosted off /blog
Alias /blog/wp-content /var/lib/wordpress/wp-content
Alias /blog /usr/share/wordpress
<Directory /usr/share/wordpress>
Options FollowSymLinks
AllowOverride Limit Options FileInfo
DirectoryIndex index.php
Order allow,deny
Allow from all
</Directory>
<Directory /var/lib/wordpress/wp-content>
Options FollowSymLinks
Order allow,deny
Allow from all
</Directory>