Functions added

editProfile.php and viewProfiles.php some stubs replaced with function
calls