Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0how to portal idhow to portal id
Previous
 
Next
New Post
5/30/2007 11:09 AM
 

Hello I'm a french guy and I'm sorry to my bad english.

I have made an instalaltion of DNN and I'm looking for a question of the fonctionality on PORTAL ID.

I have understand it take in adress bar of navigator, the string of DNS. After, it compare with the string "alais" in the database.

But I don't find how it make this. What is the Class or Object make this fonctionality.

Can you help me ?

Thanks a lot

 
New Post
5/30/2007 12:08 PM
 

Depending what your question really is, if you are within a module that inherits from UserModuleBase or PortalModuleBase, you can simply get call the property "this.PortalId" to get the portal id and "this.PortalAlias" to get the alias.  Otherwise, if you need to gather more information, you could call the following method(s) to get the portal info

DotNetNuke.Entities.Portals.PortalController pc = new DotNetNuke.Entities.Portals.PortalController();
DotNetNuke.Entities.Portals.PortalInfo info = pc.GetPortal(PortalId);

Hope that answers your question.


-- Jon Seeley
DotNetNuke Modules
Custom DotNetNuke and .NET Development
http://www.seeleyware.com
 
New Post
5/31/2007 3:57 AM
 

Thank you for your fast answer.

I seek more precise details on operation of PORTALID. I would like to find the code which permt to recover the portalID and how it makes use of it in the data base.

Have more details?

Thnaks a lot

 
New Post
5/31/2007 12:11 PM
 

From a page you can always call:

PortalSettings settings = DotNetNuke.Entities.Portals.PortalController.GetCurrentPortalSettings();

The PortalSettings object has a "PortalId" property that you can call to find out what the portalid of the current portal instance is.  If you are trying to figure out what it does in the background, I suggest you either download the sourcecode or use Reflector to disassemble the code (http://www.aisto.com/roeder/dotnet/)

The database makes pretty heavy use of portal id to decide which "portal" the tabs belong to (so the tabs table); which portal the users belong to (Users table); which portal roles are in (Roles and RoleGroups tables); and much much more.  Essentially you could say that the entire DotNetNuke process is driven by portalid because it supports multiple child portals.  Your default portal is portal 0, of course, but again, you can have any number of child portals in addition to the parent.


-- Jon Seeley
DotNetNuke Modules
Custom DotNetNuke and .NET Development
http://www.seeleyware.com
 
New Post
6/1/2007 4:11 AM
 

Thanks a lot for your answer.

I have found what I search.

 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0how to portal idhow to portal id


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out