Added Functionality for setting a function to execute once content is loaded.