Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Notification extension 0.2
Because nobody else is making an extension for notification. I will try if i can do it, I don't know if I'm able to create one, but I need it for my forum.
My idea is, that the user can mark the complete forum, single categories and single discussions to be notified. But where should i place the notify links?
I've two ideas:
1. for the discussions: at the index.php on each discussion label behind the New x, for the categories: at the categories.php behind Options: Block Categories
2. for the discussions: at the comments.php on the Panel, for the categories: if a category is selected on the Panel
What would you think, is the best way?
My idea is, that the user can mark the complete forum, single categories and single discussions to be notified. But where should i place the notify links?
I've two ideas:
1. for the discussions: at the index.php on each discussion label behind the New x, for the categories: at the categories.php behind Options: Block Categories
2. for the discussions: at the comments.php on the Panel, for the categories: if a category is selected on the Panel
What would you think, is the best way?
0
This discussion has been closed.
Comments
Now I've to make it work, that mails are sent, when new posts are created.
Another thing is, that for example Notify Discussion won't appear when the Category or the complete Forum is already activated...
How can i detect the Category of the actually selected Discussion?
I only have the DiscussionID, but I don't know how i get the CategoryID?
SELECT d.CategoryID FROM `LUM_Comment` c LEFT JOIN `LUM_Discussion` d ON d.DiscussionID = c.DiscussionID WHERE c.CommentID = whatever_your_comment_id;
there is a Join method in SqlBuilder but i've never had to use it.
//actually you could do it without an explicit join like this:
SELECT d.CategoryID FROM LUM_Comment c, LUM_Discussion d WHERE c.DiscussionID = d.DiscussionID AND c.CommentID = whatever_your_comment_id
Thanks, I thougt there is an easier method to do this, but OK
@talkshoe
Yes that's a very good idea, but I will integrate this, when the rest is finished, because it only needs to add the notification setting when the user posts something
SELECT CategoryID FROM `lum_discussion` WHERE DiscussionID = '$DiscussionID'
*needs more sleep
class NotifyDisplay extends PostBackControl { var $Name; // The name of this form function NotifyDisplay(&$Context) { $this->Constructor($Context); if ($this->PostBackAction == 'Notification') { echo '<div id="Form" class="">'; echo 'test'; echo '</div>'; } } } $NotifyDisplay = $Context->ObjectFactory->NewContextObject($Context, 'NotifyDisplay'); $Page->AddRenderControl($NotifyDisplay, $Configuration['CONTROL_POSITION_BODY_ITEM'] + 80); if (in_array($Context->SelfUrl, array('account.php')) ) $Panel->AddListItem($Context->GetDefinition('AccountOptions'), 'Notification', GetUrl($Context->Configuration, $Context->SelfUrl, '', '', '', '', 'PostBackAction=Notification'), '', '', 92);
but the code is added at the top of the complete page, how can I make, that it's display at the right place?
The user can subscribe to the complete forum, an category or a specific discussion. If a user has already subscribed to the complete forum, he's not able to subscribe to a category or a discussion and if a user has already subscribed to a category he can't subscribe to a discussion.
If the user has predefined to be notified about answers to his own discussions, the Discussion Notification for all discussions created by him, are set automatically and he can also disable the notification for his own discussions.
Every user is only once notified until he visits the forum again.
the next things, i've to do now:
- notification for comments, actually it works only for creating new discussions
- creating a new page on the account tab, where all notifications are displayed and can be deleted, there will also be the setting for notification on own discussions
If anyone has some ideas, please post it here
The Notification for comments is done, but my problem is the page in the account tab won't work...
please test it and if you find bugs post it in this thread. Also if you have some ideas to make the extension better, you can post it here.
I hope you enjoy the extension
an extension to send an e-mail to all forum users (like newsletter) would be nice, too )
"Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /var/www/s16u38/html/hessen/lussumo/extensions/Notify/default.php on line 45"
For NewsMailer this error comes after "sending" a message:
"Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /var/www/s16u38/html/hessen/lussumo/extensions/NewsMailer/default.php on line 33
Newsmailer
The message was sent."
the emails don't come....