Tuesday 19 April 2022

Fatal error: Cannot redeclare Function() in PhP

Fatal error: Cannot redeclare count_words() (previously declared) in PhP
Solution
1. Don't declare a function inside a loop. Declare before them.
or
You should include the file (wherein that function exists) only once. So instead of
include ("function.php");
use     
include_once("function.php");


No comments:

Post a Comment