Making DotNetNuke (DNN) Messaging Usable, that’s a stretch

Making DotNetNuke (DNN) Messaging Usable, that’s a stretch

I’ll start this post off by stating a few things. One, I don’t work for DotNetNuke Corporation anymore, but I still love this project and will continue to work with it for the foreseeable future. That being said, expect tough love from me going forward.

The messaging feature was added in DotNetNuke 6.2, and since then it might have seen a bug fix or two, but it like most other features added to DotNetNuke over the past 4 years, has remained stagnant and seen no additional enhancements.

If you would like to see some additional enhancements to the Message module please visit and vote for these items in the Community Voice on DotNetNuke.com here, here, here

Now, how can you go about trying to improve the Messaging in DotNetNuke right now?

One of the biggest problems with the messaging module is the message that actually gets sent to the email address of the person receiving the message. It contains absolutely NO information on WHERE the message came from, other than the username of the person who sent it, in the SUBJECT of the email.

Nothing about the Portal/Website, not the name of the website, not a link to the website, or even a link to the messaging page of the site so that a user could respond if they wanted to.

So how can we improve this? Well, the only way that you can, without completely hacking the Messaging module (I am seriously considering a Fork of the module is necessary if DNNCorp doesn’t step up), is to make changes to the Language Resource files in your website. You will do this by following the steps below (for the images, click on them to see a larger view of what I am referring to)

Warning: Making these changes will also likely impact your “notification” emails in DNN, but in my case that is fine cause I still want to send people back to the Messaging/Notification area.

  1. Navigate to the Admin/Languages page (I did this as a super user)
  2. imageClick on the Pencil in the language editor under the HOST option (I didn’t use SYSTEM or SITE)
  3. imageOn the left side of the page click on the + next to Global Resources, then choose the GlobalResources (no space) option to edit that resource file.
  4. imageNavigate to the EMAIL_BODY_FORMAT.Text resource, I used the following Code in that resource in order to add a hyperlink back to the messages page on SCCAForums.com, you would obviously need to put in the URL for your own page/domain. I use URLMaster with extensionless URLs, you might need the .ASPX in yours.
    1. Subject: {0}<br/>
          <br/>
      {1}
      <br/><br/>
      To reply, visit <a href="https://www.sccaforums.com/user-profile/messages/">SCCAForums.com Messages</a>
      <br/><br/>
      Please do not reply to this email.
      
          
  5. Scroll to the bottom of the page and click on the Save Resource File option. This will generate a new GlobalResources.Host.resx file, that will include only the changed resource key we modified. The way DNN handles resource files is that it loads up the SYSTEM resource files (globalresources.resx) and then if there is a HOST file (globalresources.host.resx) any changes there, override those in the system file, then the SITE files (globalresources.portal-0.resx) is loaded (if available).

So, really I guess I should have told you to edit the SITE resource file, but I actually used the HOST file, because I only have one portal in the install, and I don’t have to worry about changing the URL for different portals, but if you had multiple portals in an install and you wanted this, you should edit the SITE resource file for each portal.

How can DotNetNuke Corporation make the Messaging module actually usable, more so than hacking RESX files?

  1. Add the ability to have Tokens in the email that is sent
  2. Split the Messaging and Notification templates

Stay tuned to my blog here as I create posts like this, on how to make DotNetNuke better, maybe some of this will fall back into the core and posts like this won’t be necessary, but I don’t have much faith in that.

Recent Comments

Comment Avatar
I've done the resx hacks - and I'm looking for ways to truncate the email message body - but NOT the actual message in the DB. I simply want to reduce PRIVATE message body being emailed - and I want to get the recipient to login to read it all.
Posted By: Daniel Comp on May 2013
Comment Avatar
If only it actually DID use the host or site level resources. As of 7.0.3 it is stuck ONLY using the global resource file for the setup, so if you have multiple portals it will force you to set ONE template to be used for them all. Without setting up multiple instances of DNN, there is no good way to get a customized email template for the message center.
Posted By: Jehremie Woods on Jun 2013
Comment Avatar
Thanks for this, Chris. I definitely think the lack of effort on the emails side of the new messaging stuff has been a disappointment. Not only are the templates bad, but the options for users are bad: what if I want to not be emailed every time I get a notification? What about notification responses (accept/reject) in the email? What about so many of the other basic options that real sites need to make messaging useful? The DNN team has mentioned these things are coming, but it's been a long time now and there just hasn't been much focus on this stuff. I'm worried too that anything they do actually implement will be in DNN Social and not CE.
Posted By: Mike Ryckman on Jul 2013
Comment Avatar
In DNN 7.0.1, it seems like it is only taking the default en-US for this message. I have a site in a different language, and editing the global my-Lang.resx, doe snot have any affect. THis is a bug a assume. Doing it in the en-US global resx, DOES work, but I agree. Tokens wil lbe nice, at least simple things like FIRSTNAME and LASTNAME etc. And the subject line, PLEASE DNN, make the mail subject = the subject!
Posted By: Guss Davey on Oct 2013
Comment Avatar
We are looking to extend the messaging system - has there been any progress on this since you posted this? Thanks, Duncan
Posted By: Duncan Gallimore on Apr 2014
Comment Avatar
No real updates that I know of offhand.
Posted By: Chris Hammond on Apr 2014
Comment Avatar
Chris, I noticed that you made your email message display the actual message that came through the website... how did you do this? I am now on 7.2 but I still am looking to notify a user if they get a message or a notification but when I place the messages url it kicks them back to the home page because they are not logged in... is there a better way to do this? Thanks
Posted By: Scott Heinbach on Sep 2014
Comment Avatar
@Scott the message is displayed with the {1} token in the template. As for the login page issues, you could build out the Login page with the Redirect URL parameter (I don't have it offhand)
Posted By: Chris Hammond on Sep 2014

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.