DotNetNuke Tip: How to modify the page title with your module

DotNetNuke Tip: How to modify the page title with your module

This is actually a very simple trick to do inside of your modules, though you might need to setup an option to allow this to be turned on or off depending on what the site administrator wants the page title to be.

In C# you can use the following code

DotNetNuke.Framework.CDefault tp = (DotNetNuke.Framework.CDefault)this.Page;

tp.Title = "This is my page title";

So the next time you're coding a module and need to change the page title, it's that simple.

See you all at OpenForce07 in Vegas!

Posted from weblogs.asp.net/christoc

Recent Comments

Comment Avatar
Thanks!
Posted By: Andy McKenna on Sep 2008

Add Comment

Please add your comment by filling out the field(s) below. Your comment may need to be approved before it becomes visible.
Enter your first name for display with the comment
Enter your last name for display with the comment.
Enter your comment here.
If you can't type DNNRocks in, you can't post, plain and simple.
Submit Comment Cancel

Chris Hammond

Chris Hammond is a father, husband, leader, software developer, photographer and car guy. Chris focuses on the latest in technology including artificial intelligence (AI) and has spent decades becoming an expert in ASP.NET and DotNetNuke (DNN) development. You will find a variety of posts relating to those topics here on the website. For more information check out the about Chris Hammond page.

Find me on Twitter, GitHub and LinkedIn.