Added new features and extensions

Added custom.php to run custom commands...
Changed how functions are called, runs from secondary server, and added
a few functions.