don't show warnings php
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);error_reporting(E_ERROR | E_PARSE);error_reporting(E_ALL ^ E_WARNING); // how to display php errors on your browser :
// first step, create an error function :
$errors = array();
// now you have just to insert the function like this :
if (........){
$errors['the_name_of_the_error']='the error message';
}
// example :
// we want to display an error when the user does not correctly fill,
// in the 'password' box when registering on your website :
if(empty($_POST['password']) ||
$_POST['password'] != $_POST['password_confirm']){
$errors['errors']= "You must enter a valid password";
}
Also in PHP:
- composer update php mbstring.so missing
- check id the division is not giving rest php
- aptitude install php7.4
- debug php
- all dates the year php
- convert to string php
- $this in catch block php
- @foreach output reverse
- Fatal error: Allowed memory size of 1073741824 bytes exhausted (tried to allocate 9263312 bytes) in /home/arsalan farooq/local security.uk/wp-includes/wp-db.php
- check if strings contains certain word
- after config:cache page stucture has broken in laravel
- add today name to website by php
- Allowed memory size of 1610612736 bytes exhausted (tried to allocate 134217736 bytes) in phar in windows
- all capital in php
- change native password in phpmyadmin
- determine the date format from a string php
- collection get first element laravel
- clear cache routes laravel
- alias wipedb='php artisan db:wipe'
- get current date and time php
- conver to uppercase in php
- client ip address php
- Get the visitors ip adress php
- check if string contains php