I am using a table as an lookup and it is working fineNow I want to include a file so I put the code in Global Code as →
require_once(“includes/common.php”);The lookup is not working after putting the above code.
on the F12 Console I got an error as
Warning: require_once(includes/common.php): failed to open stream: No such file or directory in C:\wamp\www\xxx\src\userfn.php on line 144
Fatal error: require_once(): Failed opening required 'includes/common.php' (include_path='.;C:\php\pear') in C:\wamp\www\xxx\src\userfn.php on line 144
But on the other page the include is working fine. The error occurs only on the Lookup.
Since you use an “include” folder in your path (“includes/common.php”), make sure you put your file under the correct folder. If v2021, note that the global code is generated in ProjectFolder/src folder.
When I put the “includes” folder under ProjectFolder
All the page is working working fine except the Lookup page is not working.When I put the “includes” folder under ProjectFolder/src
all the page is not working and showing error as -
Warning: require_once(C:\Server\www\xxx\includes\common.php): failed to open stream: No such file or directory in C:\Server\www\xxx\src\userfn.php on line 145