PHP: Connect Mysql Database Using PDO

<!– <?php $user=’root’; $pass=’www.cheapglasses123.com’; $dbh = new PDO(‘mysql:host=localhost;dbname=yzmedu’, $user, $pass); ?> –> <?php try { $dbh = new PDO(‘mysql:host=localhost;dbname=yzmedu’, $user, $pass); // var_dump($dbh); foreach($dbh->query(‘SELECT * from message’) as $row) { echo “<pre>”; print_r($row); echo “</pre>”; } $dbh = null; }… Read morePHP: Connect Mysql Database Using PDO

Laravel 5.2 Post: TokenMismatchException in VerifyCsrfToken.php line 67:

// Route::post($uri, $callback); Route::post(‘/eyeglasses’, function () { echo ‘post’; }); When running the code under postman, the errors are: Whoops, looks like something went wrong. 1/1 TokenMismatchException in VerifyCsrfToken.php line 67: in VerifyCsrfToken.php line 67 at VerifyCsrfToken->handle(object(Request), object(Closure)) at call_user_func_array(array(object(VerifyCsrfToken),… Read moreLaravel 5.2 Post: TokenMismatchException in VerifyCsrfToken.php line 67:

Add Different Resource for EmpireCMS

Sometimes it is very difficut for us to publish an article if all the articles have 2 or more different articles resources from other sites. In this cases, we can not copy directly. We can use PHP code: