Start ::
Developers Corner ::
Block Development ::
Adding a new item to incoming content of menu/incoming block
Moderated by: Support Team
-
- rank:
-
pnHelper
- registered:
- July 2004
- Status:
- offline
- last visit:
- 10.12.07
- Posts:
- 446
Hi all,
I'm trying to add interfaces to some 3rd party modules for the incoming content area of the menu block. I've followed the code in /includes/blocks/menu.php that supports the core modules but I've run into a problem. One of the modules I tried was for incoming business listings in the bizpages module. It only works when I'm on the bizpages module page. If I'm on the home page or any other page it will not display the incoming content on the menu or incoming block. The core module stuff works no matter what page you have loaded. I've referenced http://communit...ic-49229.htm for DB connection information but still cannot understand why it only works when the module is loaded. Is the database tables for 3rd party modules loaded only when the page is loaded and not global like the core module tables ?? Any help with clues on this problem would be appreciated.
Here is my code:
-----
pnDev.com ~ featuring the PostNuke paid services forum -
- rank:
-
Steering Committee
- registered:
- December 2002
- Status:
- online
- Posts:
- 13326
You would be better off writing a module API function and calling that to get your items...
-----
Regards,
Simon
itbegins.co.uk - PostNuke Consulting
Please read the Support Guide -
- rank:
-
pnHelper
- registered:
- July 2004
- Status:
- offline
- last visit:
- 10.12.07
- Posts:
- 446
Good call. Thanks HammerHead. I'll do that and post the code here in case anybody is interested. Still wondering about how and when module-specific database tables are loaded for other projects. Are all the core tables loaded globally for some reason but 3rd party are not? I saw in code for PNphpBB2 when they check private messages they have access to the 'Messages' module tables and column, but it wouldn't work like that for when I tried to change it to the new 'pnMessages' tables and columns. Luckily due to your suggestion I realize that was the wrong approach anyways and should do as you suggest in your reply for that also. However I'm still curious to know more about why some seem accessible and others arent? Just to get better at PostNuke development overall. I read in the dev docs that tables get loaded when the module get loaded but this leaves me confused about how sometimes the table for the core modules seem accessible?
Shortly after posting this I may have found my own answer. Is this it?
edited by: pnDev, Nov 04, 2006 - 12:33 AM
-----
pnDev.com ~ featuring the PostNuke paid services forum
Start ::
Developers Corner ::
Block Development ::
Adding a new item to incoming content of menu/incoming block
