$_REQUEST['fb_sig_api_key'])); } } elseif ($op == FB_OP_INITIALIZE) { if (fb_is_tab()) { $config = _fb_tab_get_config($fb_app); if (!isset($GLOBALS['custom_theme'])) { $GLOBALS['custom_theme'] = $config['custom_theme']; } } } } /** * Implements fb_tab_form_alter. */ function fb_tab_form_alter(&$form, &$form_state, $form_id) { if (isset($form['fb_app_data']) && is_array($form['fb_app_data'])) { // Add our settings to the fb_app edit form. //require 'fb_canvas.admin.inc'; fb_tab_admin_form_alter($form, $form_state, $form_id); } } /** * Helper returns configuration for this module, on a per-app basis. */ function _fb_tab_get_config($fb_app) { $fb_app_data = fb_get_app_data($fb_app); $config = isset($fb_app_data['fb_tab']) ? $fb_app_data['fb_tab'] : array(); // Merge in defaults $config += array( 'custom_theme' => NULL, 'tab_default_name' => NULL, 'profile_tab_url' => NULL, ); return $config; }