So I have created a new Tab for a idea that I have. I successfully created a manager tab, but when I select the Manager Tab, the Settings tab stays highlighted.... along with the Manger Tab. What am I missing?
Thank you
Let me know if I should upload the admin.php file. Menu Help
Re: Menu Help
At the bottom of admin.php, you need to create a new "case" for the new tab.
Near the top of admin.php, you need a new array for the manager functions. Right after the arrays for different tab functions is a group of "if array key exists" statements. You need to integrate the new tab into that.
Near the top of admin.php, you need a new array for the manager functions. Right after the arrays for different tab functions is a group of "if array key exists" statements. You need to integrate the new tab into that.
Re: Menu Help
TOP (Line 66)
//add manager
$manager_funcs = Array ("manager" => "default");
//end manager
LINE 95 IF Array
/////ADD manager
if (array_key_exists($f, $manager_funcs) ) {
$manager_funcs[$f] = "selected";
} else {
$manager_funcs[$f] = "default";
}
////END Add manager
Line 138 <li><a href='admin.php?f=manager' class='".$manager_funcs[$f]."'>Manager</a></li>
BOTTOM
case 'manager':
include 'manager.php';
break;
//add manager
$manager_funcs = Array ("manager" => "default");
//end manager
LINE 95 IF Array
/////ADD manager
if (array_key_exists($f, $manager_funcs) ) {
$manager_funcs[$f] = "selected";
} else {
$manager_funcs[$f] = "default";
}
////END Add manager
Line 138 <li><a href='admin.php?f=manager' class='".$manager_funcs[$f]."'>Manager</a></li>
BOTTOM
case 'manager':
include 'manager.php';
break;
Re: Menu Help
I Found my error,--> $settings_funcs = Array ("manager" => "default"); Correct line is: $manager_funcs = Array ("manager" => "default");
Re: Menu Help
Editing admin.php is a real adventure!
![Laughing :lol:](./images/smilies/icon_lol.gif)
![Laughing :lol:](./images/smilies/icon_lol.gif)
![Laughing :lol:](./images/smilies/icon_lol.gif)