NMS default message editing

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
geepers
Dev Team Member
Dev Team Member
Posts: 84
Joined: Thu Nov 22, 2007 10:41 pm
Location: Canada

NMS default message editing

Post by geepers »

I've been attempting to change the default message that is loaded when creating a new message using NMS (1.0.2). I've gotten so far as to edit the

Code: Select all

$default_message_template
variable in the NMS.module.php file.

This makes no difference as each time I attempt to create a new message, it still uses the old default message value.

I've even removed cached files from the '/tmp/templates_c' folder to no avail.

Is there any way around this? Perhaps there's some other caching going on?

Any help would be greatly appreciated.

- greg
RonnyK
Support Guru
Support Guru
Posts: 4962
Joined: Wed Oct 25, 2006 8:29 pm
Location: Raalte, the Netherlands

Re: NMS default message editing

Post by RonnyK »

Greg,

I dont have access to a NMS 1.0.2 environment at the moment, but is there no template in the NMS module where the default message is shown?

Ronny
jensenbuhl
New Member
New Member
Posts: 6
Joined: Fri Nov 23, 2007 11:02 am

Re: NMS default message editing

Post by jensenbuhl »

Had the same problem, and searched intensively for the editing window. - Cant find it!
Found out though that the default message is to be found in the NMS.module.php, and that this is written to the database at installation. - So one workaround is to edit the default message in the php file, and then Uninstall NMS followed by a re-install re-install. You will loose users and other changes - but it works.

More elegant (until an edit window is accesible in the NMS admin frontend), is to edit directly in the database. The message is to be found in the database under the name "NMS_mapi_pref_default_message_template" in the table "_siteprefs" (as cmsms_siteprefs).

I use phpmyadmin to do the job.
geepers
Dev Team Member
Dev Team Member
Posts: 84
Joined: Thu Nov 22, 2007 10:41 pm
Location: Canada

Re: NMS default message editing

Post by geepers »

Thanks!

Ronny, that would be the obvious solution, but it appears to have been an oversight with the NMS module. I may hack it into the module management so my client can change it at will.

Jensen - many thanks - hadn't gone that far into the siteprefs table yet and it did the trick!!!

- greg
volume
Forum Members
Forum Members
Posts: 15
Joined: Tue May 30, 2006 5:45 pm

Re: NMS default message editing

Post by volume »

I was given the following edit a while ago...

What you can do is change this line (in NMS.module.php):
Code:

$params['message_text'] = $this->GetPreference('default_message_template','');

to

Code:

$params['message_text'] = $this->default_message_template;


Then everything should work fine.
And it did!

Full email here > http://forum.cmsmadesimple.org/index.ph ... l#msg27710
Post Reply

Return to “CMSMS Core”