I have some sensitive pages which I dont want to expose to external users. So I have put them in a folder (say xyz) and restricted the access with .htaccess for entire folder. Now lets say user have access to index.php
Is there a way for index.php to source some files from xyz and those files to remain restricted from external user.
So the structure is:
html
|
|- index.php
|- xyz
|- .htaccess
|- myfunctions.php
|- myadminpage.php
Can index.php source myfunctions.php inside it?
require_once 'xyz/myfunctions.php'