I have a main php file in the root which is included by several others on different directories ,I don't want to allow few functions written in main files to execute if included by another file. I ran an test code and tried overwriting an function by re-declaring it on including but it returned an error:
a.php
<?php
function show(){echo "a";}//This is what I want to over-ride with
include 'b.php';
b.php
<?php
function show(){echo "b";}//This is the function i want to restrict.
show();
Fatal error: Cannot redeclare abc() (previously declared in C:\xampp\htdocs\abc.php:3) in C:\xampp\htdocs\xyz.php on line xx.