I try to copy a properly working site to my localhost for maintenance work but I keep getting the next error message:
"Fatal error: Uncaught Error: Call to undefined function mysql_connect() in C:\xampp\htdocs\Midlife\Sources\Subs-Db-mysql.php:58 Stack trace: #0 C:\xampp\htdocs\Midlife\Sources\Load.php(2645): smf_db_initiate('localhost', 'database', 'user', 'password', 'smf_', Array) #1 C:\xampp\htdocs\Midlife\index.php(72): loadDatabase() #2 {main} thrown in C:\xampp\htdocs\Midlife\Sources\Subs-Db-mysql.php on line 58"
To copy the database I've usedBigdump en that worked fine so the database name and password should be fine.
I've tried to run repair_settings but that gives an arror too.
On the localmachine I use XAMPP with PHP 7.0.9 and MySQL 5.0.2.
The SMF software is version 2.0.13. I've tried to upgrade the SMF to version 2.0.14 but the result was a blank page so I restored 2.0.13 withouth problems.
I Except the problem is somewhere in the database connection but cant get a finger on the right spot.
Who helps me to solve this ?
There is no MYSQL support in PHP7+
To get things moving, try lowering your localhost PHP version to, say, 5.6 and try again. After that, you can work on upgrading to 2.0.14
So, what you say is:
SMF 2.0.13 doesnt work with PHP 7 ?
That's right. We introduced PHP7 support in SMF 2.0.14
OMG, this is real terrible.
But at least I now know what to do :(
Thanks.