PDA

View Full Version : Sharing data between modules ?


StewardManscat
05-01-2005, 10:10 AM
Site design is cmps sideblocks and 'custom content' pages.

I'd like to build some smarts into a sideblock.

Example: the custom page content is now working with data from some database category X, given by $catid

I want the sidebar to build a link which uses the current $catid

Currently, the sidebar module is evaluated before the page (custom content), so the value of $catid is not yet useful

Seems to me I have two choices:

1. The module may extract an arg from the current url

or

2. I may modify vba_cmps_include_bottom such that the module with identifier='custompage' is always evaluated before the side blocks.

Pros and cons anyone?

Brian
05-01-2005, 11:07 AM
Either method should work fine really. Extracting it from the URL sounds like it may be a little easier since you wouldn't have to change any of the default files, but I don't see any problems with either method other than that.

Our Sponsors
 

StewardManscat
05-01-2005, 12:33 PM
Thank you for the speedy reply and helpful informaton.