sql_autoload_register() method is undefined
小友
小友 2018-12-11 10:52:52
0
3
1606

function load($className) {
$path = $className.'php';
if (file_exists($path)) {
require_once($path);
} else {
echo $path.'The file does not exist, please check~~~';
}
}
sql_autoload_register('load');
echo (new Test('www.php. com'))->name;

小友
小友

reply all(3)
A 年轻在于拼

It’s so scary. I watched Peter Pig’s video for about 10 minutes. I looked and looked at it, but I didn’t find that it was sql. When I came here to watch it, I found that the correct one was spl.

p p p ~~~~

Langic

spl_autoload_register, I also made the same mistake. After using sql statements for a long time, I got used to it, hahaha

Peter-Zhu

This is the PHP standard library function, it should start with: spl, you spelled it wrong: sql

  • reply Thank you for your answer
    小友 author 2018-12-12 09:04:45
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template