Category: php

syntax error, unexpected 'use' (T_USE), expecting '{' 0

syntax error, unexpected 'use' (T_USE), expecting '{'

Problem syntax error, unexpected 'use' (T_USE), expecting '{' Code function fetchSumWithExplain($schemaTableName, $tag) use ($app) { $generateExplain = function ($sql, $header) use ($app) { $query = $app->db->prepare($sql); $query->execute(); $sqlData = $query->fetchAll(PDO::FETCH_ASSOC); $retVal = array_merge(array($header),$sqlData); return...

Install PHP Debug with XDebug on Windows for Visual Studio Code 0

Install PHP Debug with XDebug on Windows for Visual Studio Code

  If I follow exactly the instructions in the output of my analyzed at https://xdebug.org/wizard, I get this error (wtf!) : php -i > php.txt PHP Warning: Failed loading Zend extension 'ext\php_xdebug-3.0.4-7.4-vc15-nts-x86_64.dll' (tried: ext\ext\php_xdebug-3.0.4-7.4-vc15-nts-x86_64.dll...

Message: Class 'Hybridauth\Hybridauth' not found 0

Message: Class 'Hybridauth\Hybridauth' not found

Error¬†"Message: Class 'Hybridauth\Hybridauth' not found" When trying to login via Hybridauth. Solution Upgrade from Hybridauth 2.X to 3.X to fix this error Reference https://gitter.im/hybridauth/hybridauth?at=5c97d377a21ce51a20b4dc8f  

Uncaught PDOException: could not find driver 0

Uncaught PDOException: could not find driver

Fatal error: Uncaught PDOException: could not find driver in U:\Webpages\thecanadianhosting.co\app\src\db.inc.php:26 Stack trace: #0 U:\Webpages\thecanadianhosting.co\app\src\db.inc.php(26): PDO->__construct() #1 U:\Webpages\thecanadianhosting.co\app\src\db.inc.php(35): getDB() #2 U:\Webpages\thecanadianhosting.co\app\src\routes.php(14): require('U:\\Webpages\\the...') #3 U:\Webpages\thecanadianhosting.co\app\public_html\index.php(27): require('U:\\Webpages\\the...') #4 {main} thrown in U:\Webpages\thecanadianhosting.co\app\src\db.inc.php on line 26 Solution Enable...