1
tsanyao
Creating sublinks in the main menu
  • 2004/6/16 11:54

  • tsanyao

  • Just popping in

  • Posts: 6

  • Since: 2004/6/16


Hi,

i am moving some of the Squirrel mail menu (ie Compose, Addresses, Folders, etc) over to the main menu of Xoops.

Thus far i have added the following in xoops_version.php:

$modversion['hasMain'] = 1;
$modversion['sub'][1]['name'] = _MI_SQMAIL_COMPOSE;
$modversion['sub'][1]['url'] = "src/compose.php";
$modversion['sub'][2]['name'] = _MI_SQMAIL_ADDRESSBOOK;
$modversion['sub'][2]['url'] = "src/addressbook.php";
$modversion['sub'][3]['name'] = _MI_SQMAIL_FOLDERS;
$modversion['sub'][3]['url'] = "src/folders.php";
$modversion['sub'][4]['name'] = _MI_SQMAIL_OPTIONS;
$modversion['sub'][4]['url'] = "src/options.php";
$modversion['sub'][5]['name'] = _MI_SQMAIL_Search;
$modversion['sub'][5]['url'] = "src/search.php";
$modversion['sub'][6]['name'] = _MI_SQMAIL_HELP;
$modversion['sub'][6]['url'] = "src/help.php";

However, i couldn't see the new sublinks at the main menu under Sqmail. i guess i have missed out a step or two.

Please advise. Appreciate it.

2
intel352
Re: Creating sublinks in the main menu
  • 2004/6/16 14:32

  • intel352

  • Module Developer

  • Posts: 824

  • Since: 2003/11/23


goto the module menu and Update the module, it regenerates the menu

3
tsanyao
[Case closed] Thank you
  • 2004/6/17 6:00

  • tsanyao

  • Just popping in

  • Posts: 6

  • Since: 2004/6/16


No, i don't think we'd need to update neither sqmail module nor system module. The reason being there is no changes to any template file.

QUICK FIX:
Create a symbolic link of xoops_version.php in modules/sqmail/src folder. The submenu items will appear after a refresh of browser.

BUG REPORT:
The real bug lies in include/common.php, line 233,

if (file_exists('./xoops_version.php')) {

The programmer has assumed current folder (ie modules/sqmail/src in this case) instead of a absolute reference to modules/sqmail folder. This line will determine if the $xoopsModule be created. $xoopsModule is required by function b_system_main_show in modules/system/blocks/system_blocks.php to determine if sublinks for a module would be created.

Login

Who's Online

248 user(s) are online (155 user(s) are browsing Support Forums)


Members: 0


Guests: 248


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits