Previous Thread
Next Thread
Print Thread
Hop To
Joined: Oct 2007
Posts: 22
stranger
stranger
Joined: Oct 2007
Posts: 22
Hi,

When someone has their preferences set to email them when they get a private message, the email includes the actual text of the message. I would like to force the user to have to sign-in on the fourm to read the actual message. The email should only say that they have a new private message waiting.

Could someone please tell me where to delete/alter the code to accomplish this.

Thanks.

Daniel.


If you're 20 and not a Liberal, you have no heart. But if you're 40 and still a Liberal, you have no brain.
Joined: Jun 2006
Posts: 16,532
Likes: 150
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,532
Likes: 150
This is my stance as well... I'd at least like to have the choice wink...


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Jun 2006
Posts: 3,839
Likes: 1
I
Ian Offline
Carpal Tunnel
Carpal Tunnel
I Offline
Joined: Jun 2006
Posts: 3,839
Likes: 1
You would need to alter sendmessage.inc.php and edit the line

$msg = "{$ubbt_lang['PRIV_BODY_R']}\n\n$RawBody\n\n{$ubbt_lang['PRIV_BODY_R_SIG']}";

Remember to backup any files before editing them.

Untested, but altering this line should do the trick.

Joined: Oct 2007
Posts: 22
stranger
stranger
Joined: Oct 2007
Posts: 22
Thanks for the help.

I completely removed the above line from sendmessage.inc.php and it no effect on the email being sent. It still includes the actual message.

I did notice that the exact same code also appears in:

mess_reply.inc.php and sendmessage.inc.php

I guess I'll do some experimenting. :-)

-OneLung


If you're 20 and not a Liberal, you have no heart. But if you're 40 and still a Liberal, you have no brain.
Joined: Jun 2006
Posts: 3,839
Likes: 1
I
Ian Offline
Carpal Tunnel
Carpal Tunnel
I Offline
Joined: Jun 2006
Posts: 3,839
Likes: 1
oops sorry - didn't dig deep enough frown

Joined: Oct 2007
Posts: 22
stranger
stranger
Joined: Oct 2007
Posts: 22
Well, I'm not a php expert by any means, but it looks to me like if you remove the "$RawBody\n\n" variable, it should exclude the body of the message, but I did and it doesn't.

Well, at least my forum still works. Usually when I start editing php code the whole site crashes and I have to upload the backups. I have a technical degree in "cut-n-paste." ha!!


If you're 20 and not a Liberal, you have no heart. But if you're 40 and still a Liberal, you have no brain.
Joined: Aug 2006
Posts: 1,360
Likes: 2
Y
Veteran
Veteran
Y Offline
Joined: Aug 2006
Posts: 1,360
Likes: 2
Backuping is always key when modifying files laugh

If you do that, that's your get out of jail for free card smile


[Linked Image from siemons.org]
Joined: Jun 2006
Posts: 3,839
Likes: 1
I
Ian Offline
Carpal Tunnel
Carpal Tunnel
I Offline
Joined: Jun 2006
Posts: 3,839
Likes: 1
certainly should remove the message if you edited both those files, have you uploaded the modified files?

You might also wish to alter the language file for PRIV_BODY_R to advise them to log in to your forums.

Joined: Oct 2007
Posts: 22
stranger
stranger
Joined: Oct 2007
Posts: 22
OK, it works now.

I had to edit both mess_reply.inc.php and sendmessage.inc.php to remove $raw...

Thanks for the help!!

-OneLung


If you're 20 and not a Liberal, you have no heart. But if you're 40 and still a Liberal, you have no brain.
Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
:sniff: they just grow up soo fast nowadays... soon OneLung will be doing regexes in his sleep... :sniff:

good job!! laugh

Joined: Aug 2006
Posts: 1,360
Likes: 2
Y
Veteran
Veteran
Y Offline
Joined: Aug 2006
Posts: 1,360
Likes: 2
I just bought me a tool to play with regexes smile regexbuddy.

It's time I dive into this potential smile


[Linked Image from siemons.org]
Joined: Apr 2007
Posts: 3,940
Likes: 1
SD Offline
Former Developer
Former Developer
Joined: Apr 2007
Posts: 3,940
Likes: 1
regexbuddy > * :rawk:



Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
PHP 8 bug in membermanage.tmpl
by phoenix011235 - 09/08/2026 7:47 PM
Are any of these legitmate?
by Baldeagle - 09/06/2026 1:37 PM
After server reboot
by Morgan - 09/02/2026 8:27 AM
Email Settings
by Outdoorking - 05/13/2026 2:44 AM
Who's Online Now
1 members (1 invisible), 304 guests, and 96 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Ride safe!
Ride safe!
by Morgan, December 7
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Powered by UBB.threads™ PHP Forum Software 8.1.0
(Snapshot build 20260527)