Added code to check if the app is being displayed in the facebook canvas