Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: CapadY on August 14, 2017, 06:22:11 AM

Title: Site copying fales
Post by: CapadY on August 14, 2017, 06:22:11 AM
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 ?
Title: Re: Site copying fales
Post by: Shambles on August 14, 2017, 06:50:35 AM
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
Title: Re: Site copying fales
Post by: CapadY on August 14, 2017, 07:46:33 AM
So, what you say is:

SMF 2.0.13 doesnt work with PHP 7 ?
Title: Re: Site copying fales
Post by: d3vcho on August 14, 2017, 07:51:42 AM
That's right. We introduced PHP7 support in SMF 2.0.14
Title: Re: Site copying fales
Post by: CapadY on August 14, 2017, 08:39:41 AM
OMG, this is real terrible.

But at least I now know what to do :(

Thanks.