I am able to successfully create tables via the WP code, within the wp-settings.php file, just a few lines of code above where the ‘table does not exist’ errors start appearing.
The problems I am seeing commence with the inclusion of this line of code in wp-settings (around line 385):
require (ABSPATH . WPINC . ‘/update.php’);
…however I suspect that the create table queries are not being run when they should.
By unpicking the code I see that the database tables are defined in /includes/schema.php
This file isn’t included/parsed by install.php until several lines *after* wp-settings.php.
The order of inclusion, as I make it, is this (indented files included by the parent above)
wp-load.php
wp-config.php
wp-settings.php
/includes/upgrade.php
includes/admin.php
includes/schema.php
…which looks to me like it’s impossible that the tables can be created before the line in wp-settings.php, require (ABSPATH . WPINC . ‘/update.php’);.
I am clearly missing something fundamental.
Anyone any clue? My 5 minute WP install is taking days ??
Stu