Tabs display but aren't working

Discuss everything related to ApPHP Tabs. Any questions related to the ApPHP Tabs developing or using should be posted to this forum.

Moderators: alexandrleonenko, Milton

johna
Newbie
Newbie
Posts: 1
Joined: Nov 15th, '10, 15:52

Tabs display but aren't working

Postby johna » Nov 15th, '10, 16:00

I purchased the PHP tabs 3.01 and I can get the tabs to display but can't get them to rollover or switch content ?

I must be missing a piece of code . . . to make this work?

Here is the code I've inserted into my page:

<?php
define ("TABS_DIR", "../");
require_once(TABS_DIR.'tabs.class.php');
$tabs = new Tabs();
if(isset($_GET["style"]))
$tabs->SetStyle($_GET["style"]);
if(isset($_POST["submission"]))
$tabs->SetSubmissionType($_GET["submission"]);

$tabs->Debug(false);
$tabs->SetStyle("xp");
$tabs->SetSubmissionType("get");
$tabs->AllowRefreshSelectedTabs(true);
$tabs->SetHttpVars(array("submission","style"));



$atmosphere = $tabs->AddTab("MODULE I ATMOSPHERE","content/mod1.html");
$ocean = $tabs->AddTab("MODULE II THE OCEAN","content/mod2.html");
$atmosphere2 = $tabs->AddTab("MODULE III ATMOSPHERE","content/mod3.html");
$synmeterology = $tabs->AddTab("MODULE IV SYNOPTIC METEROLOGY","content/mod4.html");
$thunderstorms = $tabs->AddTab("MODULE V THUNDERSTORMS","content/mod5.html");
$lightning = $tabs->AddTab("MODULE VI LIGHTNING","content/mod6.html");
$tropweather = $tabs->AddTab("MODULE VII TROPICAL WEATHER","content/mod7.html");
$satimages = $tabs->AddTab("MODULE VIII SATELITE IMAGES","content/mod8.html");

$tabs->SetDefaultTab($atmosphere);
$tabs->Display();
?>

administrator
Site Admin
Site Admin
Posts: 5997
Joined: Jan 7th, '09, 23:18
Contact:

Re: Tabs display but aren't working

Postby administrator » Nov 16th, '10, 08:34

The code is ok, try to remove

this:

if(isset($_GET["style"]))
$tabs->SetStyle($_GET["style"]);
if(isset($_POST["submission"]))
$tabs->SetSubmissionType($_GET["submission"]);

and this:
$tabs->AllowRefreshSelectedTabs(true);
$tabs->SetHttpVars(array("submission","style"));

Turn 'debug on' to see what happens.
Does it help now?

Trevis
Newbie
Newbie
Posts: 1
Joined: Jan 2nd, '15, 12:31

Re: Tabs display but aren't working

Postby Trevis » Jan 2nd, '15, 12:32

Happy new year and marry chrimiss
------->


Return to “ApPHP Tabs”