Parse error: syntax error, unexpected T_STRING in /wp-config.php on line 1
-
[ Moderator Note: Please post code or markup snippets between backticks or use the code button. ]
We installed WP Multisite into a subdomain directory for staging and testing before going live with a new version of our website. We thought this would make life easier for us, or so we thought. We have the site fully built and tested, working fine at subdomain.maindomain.com and the WordPress files all work great where they are installed in a folder called /subdomain
The problem is that today we planned to simply move the files over to the root directory- no need to change the database settings or anything like that – just thought we would modify wp-config.php slightly from
define('WP_DEBUG', true); define('MULTISITE', true); define('SUBDOMAIN_INSTALL', false); $base = '/'; define('DOMAIN_CURRENT_SITE', 'subdomain.maindomain.com'); define('PATH_CURRENT_SITE', '/'); define('SITE_ID_CURRENT_SITE', 1); define('BLOG_ID_CURRENT_SITE', 1); /* That's all, stop editing! Happy blogging. */ /** Absolute path to the WordPress directory. */ if ( !defined('ABSPATH') ) define('ABSPATH', dirname(__FILE__) . '/'); /** Sets up WordPress vars and included files. */ require_once(ABSPATH . 'wp-settings.php'); define('WP_ALLOW_MULTISITE',true);
to this:
define('WP_DEBUG', true); define('MULTISITE', true); define('SUBDOMAIN_INSTALL', false); $base = '/'; define('DOMAIN_CURRENT_SITE', 'www.maindomain.com'); define('PATH_CURRENT_SITE', '/'); define('SITE_ID_CURRENT_SITE', 1); define('BLOG_ID_CURRENT_SITE', 1); /* That's all, stop editing! Happy blogging. */ /** Absolute path to the WordPress directory. */ if ( !defined('ABSPATH') ) define('ABSPATH', dirname(__FILE__) . '/'); /** Sets up WordPress vars and included files. */ require_once(ABSPATH . 'wp-settings.php'); define('WP_ALLOW_MULTISITE',true);
Now we get this T_STRING error on https://www.maindomain.com – HELP!
- The topic ‘Parse error: syntax error, unexpected T_STRING in /wp-config.php on line 1’ is closed to new replies.