how do i reference a function that is in a seperate php file?
If your file with functions is called functions.php then you just do:
<? include("functions.php"); ?>
Then you just reference the function normally.