PDA

View Full Version : [RELEASE] Email Notification Hack v0.1


08-31-2000, 05:17 AM
This hack will add a link to the notification emails that are sent out to your users. Clicking on this link will disable email notification for the thread that generated the notification for that user. The hack also shows a small snippet of the new post.

You need to edit your notifyemail template and place something like this in it. Format as you see fit. $snippet is the text from the message.


Text Snippet:
~~~
$snippet
~~~

If you no longer want to receive notification of replies to this thread then please click here:
$bburl/notifyoff.php?threadid=$threadid


edit newreply.php and find:

$toemail=$useremail[email];


Directly after that place:

// Email Notification v0.1 Begin
if (strlen($message) > 160)
{ $snippet = substr($message,0,160) . "(...)"; }
else { $snippet = $message; }
// Email Notification v0.1 End


Change the two instances of 160 in the above code to the number of characters you want your text snippet to be.

Download the hack at http://www.hedgehogwheels.com/forums/notifyoff.php.txt and name it notifyoff.php

I think I am going to turn this into a full fledged email notification hack that has a centralized area to add and remove your subscribed threads and adds an icon to all threads that allows you to quickly subscribe to a thread without posting to it. Don't hold your breath on it though :)

[Edited by rangersfan on 08-31-2000 at 02:17 AM]

08-31-2000, 05:21 AM
okay going to add it in a sec... and let you know :D

08-31-2000, 05:24 AM
Also if you don't want to edit any of your files, then just remove the "snippet" part from your notifyemail template and you can still use the disable enmail notification part of the hack.

Eva I made a post on your forum at http://animeboards.net/forums/showthread.php?threadid=2058 reply to it when you get the hack up.

[Edited by rangersfan on 08-31-2000 at 02:26 AM]

08-31-2000, 05:31 AM
just added the hack and replied to that thread you did... reply again and see if i get the message :D

08-31-2000, 05:34 AM
You can verify it works by editing your messages and seeing that the "email notification" box is now unchecked. Remember if you make a new post and have that box checked then notifies will resume.

08-31-2000, 05:37 AM
yep checked the original post and my notify is off :D ... another great hack rangersfan https://vborg.vbsupport.ru/

08-31-2000, 05:39 AM
It sets it off for every post in the thread as any of them being checked will trigger an email notify.

08-31-2000, 05:42 AM
i see... now all we need is Ed and vb hackers site to open it's doors and you can get your hacks up on the site :D

08-31-2000, 08:07 AM
hm... would that qualify as a silent hint?

09-02-2000, 02:37 AM
rangersfan:

Don't you have to have the emailnotification enabled for the user too? I have the emailnotification set to 0 for all of my members instead of being set at a default of 1. So if the emailnotification is set to zero for the user does it still allow tracking of the the thread?

Thanks,
Parker

09-02-2000, 03:56 AM
Set to 0 just means that the email notification box for each message is unchecked by default.

09-02-2000, 05:18 AM
rangersfan:

I think I am going to turn this into a full fledged email notification hack that has a centralized area to add and remove your subscribed threads and adds an icon to all threads that allows you to quickly subscribe to a thread without posting to it. Don't hold your breath on it though

I LOVE this idea. I would would much prefer having a central area to go to when you want to track a thread. For example if you were to want to track a thread you would just click a tracking button in the reply area and it would take you to a page that would allow you to enable or disable the tracking of this thread. If you didn't want to track it any more you would click on the same tracking button and you could now disable it.

Parker

09-05-2000, 10:39 PM
Originally posted by rangersfan
I think I am going to turn this into a full fledged email notification hack that has a centralized area to add and remove your subscribed threads and adds an icon to all threads that allows you to quickly subscribe to a thread without posting to it. Don't hold your breath on it though :)

[Edited by rangersfan on 08-31-2000 at 02:17 AM]

That's great, we really need this hack.

Thank you. :)

09-06-2000, 02:09 AM
An idea for the new version:
In addition to subscribing to threads, what about enabling people to recieve a notification when specific user post a message?

10-04-2000, 06:24 AM
Rangersfan - first off thanks for the hack. Second I keep getting my notification emails looking like this now that I installed this hack:

Hello, Bad ?ss with a Gun! has just replied to your thread entitled - About tired of it..... - in the Flames Forum forum of PaintballCity.com Message Boards. This thread is located at: http://forums.paintballcity.com/showthread.php?threadid=51257 If you no longer want to receive notification of replies to this thread then please click here: http://forums.paintballcity.com/notifyoff.php?threadid=51257 Post Preview: ~~~~~~~~~~~~~ Originally posted by Bungalow See your opinion doesn't count because you are a moderator, therefor you will take up for Jim because you are s(...) ~~~~~~~~~~~~~ There may be other replies also, but you will not receive any more notifications until you visit the thread.


It does not keep the line breaks that I have in my otifyemail template.

Any ideas?

10-04-2000, 01:41 PM
You have to put newlines into your template so that they will appear as you want. newline character is:

\n

10-12-2000, 09:43 AM
That doesn't work

10-15-2000, 11:17 AM
The download dosen't work! Can anyone send me or post a new link to the file?

cd@kowtun.de

10-15-2000, 02:04 PM
link doesnt work! can anyone give us an original copy??

10-15-2000, 09:24 PM
The link works now.

10-29-2000, 04:53 PM
came across your hack (good plan putting them in your sig!)

The new features for version 2.0 look brillaint but little emphasis seems so far to have been placed on linking the forum with email (probably because of the perhaps future plan for web based email).

Anyway, now that we have a control panel in the works (myVB) i hope you will go back to your original plan and encorporate subscription to threads of this sort and better options (like mass unsubscribe with checkboxes etc) into the next version. Would be very very cool!

10-29-2000, 05:54 PM
Just installed this at SitePoint and gotten positive comments from one user so far. It has only been installed for about an hour so far.

Nice simple addition, so simple it should be in 1.1.4.

Only enhancement that I would like is that it skips over quoted replies. Going to look into seeing if that can be accomplished.

10-29-2000, 07:03 PM
it skips quoted replies ?

10-30-2000, 01:53 AM
I don't understand exactly what you mean by skip over quotes....Do you mean to not have the quoted part sent in the user's notify email, just the new post?

You see I have so many ideas and bounce around to different hacks that I am lucky to actually finish any single hack..

10-30-2000, 02:27 AM
Yes, Rangersfan is correct. I would like it to ignore the quoted part of the message and just pull the snippet from the new message.

Right now if a member hits quote and replies to a message, the email states something like:

Originally posted by: Membername
this is a quoted replay and it displays up to 160 characters because I left the default.


Now Rangersfan:

It was a suggestion. I know everyone has a site to run of their own and I know your busy. This is something that is not critical. I just thought I would mention it.

10-30-2000, 02:28 AM
I would have to look for the [ quote ] tags and disallow the text in between. I could easily use a stack to do it but it is not something I have time to do right now. Have to work on that calendar hack!

10-30-2000, 04:54 PM
Originally posted by rangersfan
I would have to look for the [ quote ] tags and disallow the text in between. I could easily use a stack to do it but it is not something I have time to do right now. Have to work on that calendar hack!

Like I said, no hurry. If I get the time to look into it, I will.

I have one other problem which was reported to me last night and I am not sure how to resolve it. I think it might be a setting in the user's email program. I know it isn't a code problem because only one user has reported this problem and I get the same emails fine.

On the post reply I get:

Hello,

mkaufman has just replied to the thread entitled - SitePointForums.com Suggestions - Please Read - in the SitePoint Feedback forum of SitePoint Community Forums.

This thread is located at:
http://www.sitepointforums.com/showthread.php?threadid=10935&goto=newpost

Text Snippet:
~~~
Also, it says:

Welcome TO our newest member, [membername]

That doesn't make much sense..it's like that on all vBulletin boards.
~~~

If you no longer want to receive notification of replies to this thread then please click here:
http://www.sitepointforums.com/notifyoff.php?threadid=10935

There may be other replies also, but you will not receive any more notifications until you visit the community.

Which is exactly how it should be. The user having the problems gets the same email as:

Hello,mkaufman has just replied to the thread entitled - SitePointForums.com Suggestions - Please Read - in the SitePoint Feedback forum of SitePoint Community Forums.This thread is located at:http://www.sitepointforums.com/showthread.php?threadid=10935&goto=newpostText Snippet:~~~Also, it says:Welcome TO our newest member, [membername]
That doesn't make much sense..it's like that on all vBulletin boards.~~~If you no longer want to receive notification of replies to this thread then please click here:http://www.sitepointforums.com/notifyoff.php?threadid=10935There may be other replies also, but you will not receive any more notifications until you visit the community.


Now I understand this is a very weird problem and I am just looking for a little input from others and would like to know if anyone else had this problem.

11-30-2000, 01:48 PM
it's simple......but it works great
actually probaly one of the easiest hacks to install
practically no problems

12-01-2000, 11:40 AM
After about a month without problem, today I got this error:

" Database error in vBulletin: Invalid SQL: SELECT title from thread where threadid =
mysql error: You have an error in your SQL syntax near '' at line 1
mysql error number: 1064
Date: Wednesday 29th of November 2000 06:35:34 AM
Script: /forums/notifyoff.php3?threadid?8
Referer: ".

Anyway my forum had no apparently problem and still works.
I've Vb 1.1.4 installed.

Can anybody explein me why this error and only once?

Thanks

12-01-2000, 12:28 PM
"/forums/notifyoff.php3?threadid?8"

-- Change the second ? to an = .

12-01-2000, 01:12 PM
Originally posted by Ed Sullivan
"/forums/notifyoff.php3?threadid?8"

-- Change the second ? to an = .

Sorry, where?

Sinotto

01-03-2001, 05:31 PM
well it looks like this thread is needed for when i replace v.1.1.5's newreply.php

any changes i need to know about with re-adding this notifyoff hack to v.1.1.5's newreply.php file ?

01-03-2001, 07:41 PM
Originally posted by eva2000
well it looks like this thread is needed for when i replace v.1.1.5's newreply.php

any changes i need to know about with re-adding this notifyoff hack to v.1.1.5's newreply.php file ?


Nope.. Just reinstall it as before. :)

Streicher
06-11-2001, 04:43 PM
How can i make this hack working for vB 2, bceaus i can't find $toemail=$useremail[email]; in newreply.php?

tubedogg
06-11-2001, 08:09 PM
This is already in 2.0...?

Streicher
06-11-2001, 08:12 PM
Originally posted by tubedogg
This is already in 2.0...?

Yes, the notfication, but not the feature to send the first x characters of the post with the notification.

kreker
06-16-2001, 08:58 AM
works with vbb 2.0.1?

Streicher
06-17-2001, 08:19 AM
I have found a way. Put the variable $message in the E-Mail Notify Template and the complete message is in the E-Mail.

theflow
09-08-2001, 10:08 AM
Originally posted by Essam
An idea for the new version:
In addition to subscribing to threads, what about enabling people to recieve a notification when specific user post a message?

I like this idea a lot. Does anoyone have an idea of how difficult this would be to do?