In PHPMaker you can use the following code in Page_Head or Page_Foot to load your own custom scripts:
$page = basename($_SERVER['PHP_SELF']);
if (file_exists("../my/code/$page.php")) { AddStylesheet("../my/code/$page.php"); // Add PHP script }
if (file_exists("../my/code/$page.css")) { AddStylesheet("../my/code/$page.css"); // Add CSS stylesheet }
if (file_exists("../my/code/$page.js")) { AddClientScript("../my/code/$page.js"); // Add JavaScript }
In the above code, we use "../my/code/" as the base path for the CSS and JavaScript files. We then check if the files "../my/code/$page.css" and "../my/code/$page.js" exist using the file_exists() function. If they do, we add the CSS and JavaScript files using the AddStylesheet() and AddClientScript() functions respectively.