I have been in toruble with kind of conflict issue. There is a Database Class which contains connection, update, delete, insert, fetch methods and also there is User Class which extends Database Class.
class User extends Database {...}
Problem is, when I initialize the Database class and User Class at the same time in "index.php", I get an fatal error which says "Fatal error: Cannot redeclare class Database".
include "database.class.php";
include "user.class.php;
$db = new Database;
$db->connect();
So, I am aware of initializing database class twice, but how can prevent not to happen? P.S.: I can use Database class in other new classes.