DotNetNuke – Modules – Portal Specific Modules

misc_vol3_033 Many of you won’t care too much about creating Portal Specific Modules because you’ll be creating modules for an environment that only has one portal. However, if you are creating a module for resell, or you will be using the module in a multi-portal environment, you’ll need this next piece of information I’m going to give you.

In fact, I should have given you this information when I told you how to set up your databases. Sorry.

Each module instance will have its own module ID. What this means to you as a developer is that your top-level table(s) need to have a ModuleId field (integer) that can be filled with the module ID the data should be associated with.

This will allow you to install the module multiple times on your site or on multiple portals without having the data conflicting with the other instances or other modules.

You might also want to put the PortalId in all of your tables so that it is easy to remove data when a table is removed. Or you might want to implement a cascading delete. That part of the implementation is totally up to you.

The important point is that you need to have some way of associating the data in your database with the portal it should display in. Adding the ModuleID field is how you do this.

Thanks to Charles Nurse for his help with this topic

 


Other post in DotNetNuke - Module Development

Other Related Items:

PNY OPTIMA 1GB  DDR 333 MHz PC2700  Notebook / Laptop SODIMM Memory Module MN1024SD1-333PNY OPTIMA 1GB DDR 333 MHz PC2700 Notebook / Laptop SODIMM Memory Module MN1024SD1-333Random Access Memory (RAM) is the key to optimum system performance. The amount of RAM you install in your PC will impact the number of programs your system can run simultaneously and how efficiently each application will perform.
PAC TR7 Universal. Trigger ModulePAC TR7 Universal. Trigger ModuleCombines several triggering functions in 1 package, providing a solution for a multitude of problems Accurate digital timing without the use of sepa... Read More >
Access Virus Version C Desktop SynthAccess Virus Version C Desktop SynthEqually comfortable in professional studios or beside a home computer, as well suited to clubs and concerts as it is to museum soundtracks, the Virus C Desktop Synth is heir to a legendary line of predecessors, and it inherits their incredible musical traditions with flying colors.

Related Post

One Response to “DotNetNuke – Modules – Portal Specific Modules”

DotNetNuke Sponsor

 

Most Valuable Blogger
Sponsor