On my local machine, I have multiple wordpress versions installed so I can test the themes and plugins I develop.
I was wondering if I could somehow create a central wp-content folder and database, which are linked to each version of wordpress, so I don’t have to continually copy my projects between the them?
For
wp-content
folder you need to add WP_CONTENT_DIR with path to this folder to eachwp-config.php
file of each your sites. All of these WP_CONTENT_DIR constants should have the same path to one folder. Read more about it here: http://codex.wordpress.org/Editing_wp-config.php#Moving_wp-contentTo share the same database, you just need to setup the same database settings in each
wp-config.php
files. Read about it here: http://codex.wordpress.org/Editing_wp-config.php#Set_Database_NameUPDATE: To make your urls work correctly define
WP_SITEURL
andWP_HOME
constants which will override options settings. Read about it here: http://codex.wordpress.org/Editing_wp-config.php#WordPress_address_.28URL.29Have you considered a WordPress Multisite Network setup? Have you considered WordPress (Multisite) Network setup? Take a look at this: http://codex.wordpress.org/Create_A_Network