Hi,
I have problem with customising code for Tabs on Facebook Pages: Complex Case, using hook_fb_tab(), from
http://drupal.org/node/956034
I have successfully customised part of the code that builds a form when directed to configuration section of a tab for a particular page (option FB_TAB_OP_FORM ). I have a form that simes to work because, if I do a relode of this the default option in the form is the option that was chosen before a relode. The chosen option sims to be saved in $data['config']['eg_fb_og']
Now the $data['config']['eg_fb_og'] should be set and after I return to the page tab count($data['config']) should give TRUE condition and this part of the code
if (count($data['config'])) {
// We have been configured, we can show a group.
$og = node_load($data['config']['eg_fb_og']);
og_set_group_context($og);
drupal_set_title($og->title);
// Show the default "river of news"
$return['eg_fb_og'] = array(
'#type' => 'markup',
'#value' => views_embed_view('og_ghp_ron', 'default', $og->nid),
);should be run. But instead I'm directed again to configuration section. Also if I try to check and print_r($data['config']['eg_fb_og']) on screen I don't get anything on screen.
Thanks,
Comments
Comment #1
Dave Cohen commentedAre you using the new iframe tabs or the older FBML tabs?
Comment #2
Dave Cohen commentedI have a patch in progress for the iframe tabs, FBML is deprecated. Are you up for helping me test that?
Comment #3
Damjan Dvorsek commentedI'm using iframe, I thought that there shouldn't be any problem with that, since I had no problem when I wanted to show same chosen nodes in the tab. I'm having a problem with this
$data['config']['eg_fb_og']when option FB_TAB_OP_VIEW should run andif (count($data['config']))should be TRUE . I think option FB_TAB_OP_FORM work as it should. The selection from the form gets saved in the database tabel.I would gladly help you test the patch.
Comment #4
Dave Cohen commentedSee patch in #1121302: Support iframe page Tabs.
Attempting to consolidate page tab issues. If you feel this is not a duplicate, please change status back to active. My hope is that when iframe-based tabs are fully supported, this issue will be resolved.
#1121302: Support iframe page Tabs
Comment #5
problue solutionsThis is sounding very like something I'm experiencing towards the bottom of this thread: http://drupal.org/node/1100496
How do I know if im using iframe or FBML tabs? Im pretty certain its iframe as I'm not using an FBML theme and everything is displayed ok, but I cant find any setting for iframe/FBML.
Am i using iFrame simply because the "Theme for profile tabs" is set to a non-FBML theme?? Or is there anything else that designates whether the tabs are iFrame or FBML?