Simple Machines Community Forum

Customizing SMF => Tips and Tricks => Topic started by: rea on October 02, 2005, 12:33:04 PM

Title: notify unnotify.
Post by: rea on October 02, 2005, 12:33:04 PM
I was trying to search, but
QuoteDue to high stress on the server, the search function has been automatically and temporarily disabled. Please try again in a short while.

Tought yesterdar I search for this (the topic) and only find one coincidence if Im not wrong.



I have sended the following to a board that use this software, but the guy there say that he will not change the source, because he dont know if in next realeases, this same change can be applied

Quote
Post this at the SMF development site as a suggestion. For now, I am not doing any modifications to this forum software that is simply going to be erased with the next release.


Here is my post:

<======================================================================>




I normally like to add notify button, but sometimes I do hit the button a second time doing a unnotify action, I normally dont read the text and I miss sometimes that say "you whant to disable notification..." that is bad, then I have taked a look there for see how to handle this and that the button reflect the state of the actual notification.

This is how I get over...

if SMF is where the board software is, then:


in directory:
SMF\Themes\default\
search for:
Display.template.php


In that file search for

if ($context['can_mark_notify'])
$buttonArray[] = '<a href="' . $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id'] . '" onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/notify.gif" alt="' . $txt[131] . '" border="0" />' : $txt[131]) . '</a>';



or more simple for:
if ($context['can_mark_notify'])

The end of the next line ("$buttonArray[] = ... $context['user']['language'] . '/notify.gif" alt="' . $txt[131] . '" border="0" />' : $txt[131]) . '</a>';")
will be the one that will be changed for the next code

$context['user']['language'] . ($context['is_marked_notify']?'/unnotify.gif" alt="':'/notify.gif" alt="') . $txt[131] . '" border="0" />' : $txt[131]) . '</a>';


I also attach a little modification of "notify.gif" resulting in "unnotify.gif" see that Im not good at draw in computer...

By the way, "unnotify.gif" should be saved inside the folder "SMF\Themes\default\images\english\"


Hope you can check it and do this little change (for the guys that like to follow what the button say and bypass time to time the message boxes).

<======================================================================>


That was, and here Im.


Here I cant attach unnotify.gif :S, but I only draw a "un" in front of notify (in white) and with the color blue of the gif (that is used in that board... default skin) I do a cross in the antenna :).



Dont know if this is the correct way to do this, I mean, for be used in this and future realeases of the software, by the way, I have tested it with "Powered by SMF 1.0.5.".
Title: Re: notify unnotify.
Post by: xenovanis on October 02, 2005, 04:02:24 PM
Can you mail me the button so I can attach it to your post? For now, I will move this to the Tips and Tricks board.
Title: Re: notify unnotify.
Post by: pctwo on October 01, 2006, 11:54:47 AM
for 1.1RC3, the code is slightly different.

In both Display.template.php and MessageIndex.template.php change this


'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif',


to


'notify' => array('test' => 'can_mark_notify', 'text' => $context['is_marked_notify'] ? 'unnotify' : 125, 'image' => $context['is_marked_notify'] ? 'unnotify.gif' : 'notify.gif',


Note: the rest of the line stays the same

Grab the unnotify.gif in the first post and put it as instructed in the first post.  Then add this to your Themes/theme-name/languages/index.english.php

$txt['unnotify'] = 'UnNotify';
Title: Re: notify unnotify.
Post by: nitins60 on December 17, 2006, 12:22:29 PM
Hope it will be fixed in next SMF version
Title: Re: notify unnotify.
Post by: videoman57 on December 02, 2008, 05:03:45 PM
Is there a feature in a gallery for smf that allows you to be notified when someone adds a comment to your photos.
Title: Re: notify unnotify.
Post by: Oldiesmann on February 02, 2009, 11:04:06 PM
I'm fairly certain that SMF Media Gallery includes this option. Not sure about Coppermine or SMF Gallery.
Title: Re: notify unnotify.
Post by: Piper on April 17, 2009, 07:02:41 PM
I wonder id someone could write a Mod for this.  This is the biggest problem I have with SMF.  My users don't remember to click notify or double-click. 
Title: Re: notify unnotify.
Post by: Sarge on May 08, 2009, 02:06:32 AM
videoman57, Piper, have you managed to find a solution?
Title: Re: notify unnotify.
Post by: videoman57 on September 20, 2009, 10:35:19 PM
no, i have never heard any response regarding this!
Thanks for asking!
Title: Re: notify unnotify.
Post by: Arantor on October 11, 2009, 05:46:25 AM
Did you ask in the support topic for the gallery mod?
Title: Re: notify unnotify.
Post by: videoman57 on October 24, 2009, 05:07:36 PM
I presented this idea to smf media gallery and they will consider it as a mod called foxy in the future?
I did not know if the gallery lite mod had this option or not. Thanks again for the response!
Jim