Page 1 of 1
NMS default message editing
Posted: Thu Nov 22, 2007 10:59 pm
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
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
Re: NMS default message editing
Posted: Fri Nov 23, 2007 7:32 am
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
Re: NMS default message editing
Posted: Fri Nov 23, 2007 11:17 am
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.
Re: NMS default message editing
Posted: Fri Nov 23, 2007 5:32 pm
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
Re: NMS default message editing
Posted: Tue Dec 04, 2007 4:12 pm
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