If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Enjoy an ad free experience by logging in. Not a member yet? Register.

reisve, you should not use the word java when you mean javascript. It confuses people.

The script is located in a subdirectory in the root of the site called java.

Using folder called js or javascript would be better. I said 'would ' don't mean that it's mandatory. You could call it 'fishFingers' if you wanted to but it would confuse people. You should not use 'echo a php variable' when none exist.
And something important

Your main code should be on the same level as your sub-folders.
In other words index.php(this is your main file) exists with folder js and folder templates and, if you had pictures, folder images.
You call the templates (and I would use the .html on them not .tpl) by naming your main file as index.PHP and then using :

PHP Code:

<?php
include("templates/header.html");
?>

Where you want the header to appear. Same for a footer, if you have one, and same for the js.
Where you want the js:

<?php
include "lib/configuration.php";
include "language/frontend/portuguese.php";

include "templates/frontend/header.tpl";
include "templates/frontend/loginspace.tpl";
include "templates/frontend/registerlogin.tpl";
include "templates/frontend/searchspace.tpl";
include "templates/frontend/search.tpl";
include "templates/frontend/hmenuspace.tpl";
include "templates/frontend/menubar.tpl";
include "templates/frontend/leftspace.tpl";
include "templates/frontend/leftside.tpl";
include "templates/frontend/contentspace.tpl";
include "templates/frontend/centerwelcome.tpl";
include "templates/frontend/centerlisting.tpl";
include "templates/frontend/rightspace.tpl";
include "templates/frontend/rightside.tpl";
include "templates/frontend/footerspace.tpl";
include "templates/frontend/footerdiv.tpl";
include "templates/frontend/footer.tpl";
?>