Install WordPress with custom paths using Composer.
This repository is a base to install WordPress with Composer. You can customize the installation the way you want but make sure to update all the paths/names.
-
Download the
your-wordpress-website
folder (you can clone and remove everything except this folder). -
(Optional) rename
htdocs
to match the public folder of your host. For example, with Gandi, it'shtdocs
. Other hosts can usewww
. If you renamehtdocs
, you will need to update thecomposer.json
file to suit your needs. -
(Optional) rename
wp
andwp-content
. Again, you will need to update some paths in this case. -
Then, go inside the
htdocs
directory to copy and renamewp-config-sample.php
towp-config.php
. -
Inside the file, replace:
- the path to Composer autoload if different
- the database info (
"database_name_here"
,"username_here"
,"password_here"
,"localhost"
) - all the "Authentication Unique Keys and Salts"
"wp_"
table prefix (if needed)"WP_SITEURL"
value with your URL to core directory (/wp/
by default)"WP_HOME"
value with your URL- uncomment
"FORCE_SSL_ADMIN"
(if needed)
- Open a terminal, then:
composer install
This project is open source and available under the GPL-2.0-or-later license.