Dear FireBoard users,
In order to further develope the need of Joomla for a robust forum, FireBoard component has been moved to its own new home and new name. You can find more information regarding the Kunena, the successor of FireBoard, at kunena.com. The current forum here will stay for some time more for referencing needs. You can find the FireBoard files under joomlacode.org and other files
Upgrading to Kunena is highly recommended!

Kunena! - To Speak!

A revolution is coming... Kunena - Swahili for: To Speak! THE Next generation of native Joomla based Forum ultra component. Forget what you know about Joomla based forums...
Amazingly Simple Lean and Clean Easier Customization
Kunena is about to redefine the world of Joomla! with the most simplistic ultra component out there. For ultimate performance based on state of the art development techniques, Kunena! is about to bring you... With an integrated plugin system that will allow you to extend Kunena beyond your wildest imaginations...
[SOLVED] New messages are sent to all users
TOPIC: [SOLVED] New messages are sent to all users
#47363
[SOLVED] New messages are sent to all users 9 Years, 8 Months ago  
I am running Fireboard 1.04 with Community Builder. I recently changed the configuration of Fireboard (security):
- Email Moderators: No
- Email Administrators: Yes

With this configuration new posts were sent to [b]every user[/b] which opted to receive moderator emails (field sendEmail=1 in table jos_users) and not only the administrators!

I quickly turned off the Email Administrator option and analyzed the code.

The following code change is needed to fix this issue:
Filename: post.php (components/com_fireboard/template/default)
Lines: 350 ff

Old code:
[code:1]if($fbConfig[\'mailadmin\']==1) {
if(strlen($sql2)) { $sql2 .= \"\\n OR \"; }
$sql2 .= \" u.sendEmail=1\";
}[/code:1]


New code:
[code:1]
if($fbConfig[\'mailadmin\']==1) {
if(strlen($sql2)) { $sql2 .= \"\\n OR \"; }
$sql2 .= \" u.gid >= 24 AND u.sendEmail=1\";
}
[/code:1]

This solved my issue

Stephan
#47363
[SOLVED] New messages are sent to all users 9 Years, 8 Months ago  
I am running Fireboard 1.04 with Community Builder. I recently changed the configuration of Fireboard (security):
- Email Moderators: No
- Email Administrators: Yes

With this configuration new posts were sent to [b]every user[/b] which opted to receive moderator emails (field sendEmail=1 in table jos_users) and not only the administrators!

I quickly turned off the Email Administrator option and analyzed the code.

The following code change is needed to fix this issue:
Filename: post.php (components/com_fireboard/template/default)
Lines: 350 ff

Old code:
[code:1]if($fbConfig[\'mailadmin\']==1) {
if(strlen($sql2)) { $sql2 .= \"\\n OR \"; }
$sql2 .= \" u.sendEmail=1\";
}[/code:1]


New code:
[code:1]
if($fbConfig[\'mailadmin\']==1) {
if(strlen($sql2)) { $sql2 .= \"\\n OR \"; }
$sql2 .= \" u.gid >= 24 AND u.sendEmail=1\";
}
[/code:1]

This solved my issue

Stephan
#47678
Re:[SOLVED] New messages are sent to all users 9 Years, 8 Months ago  
Thanks for this!!!

ALL my users are also getting moderator emails.

Could you please tell me what this \'u.gid >= 24 AND\' is doing?

-Tom
#47685
Re:[SOLVED] New messages are sent to all users 9 Years, 8 Months ago  
Every user in Joomla belongs to a specifc group; this is specified in the table jos_users. The available groups are defined in the table jos_core_acl_aro_groups:

A default Joomla 1.5 installation always contains the groups (extract from the table):
[code:1]
| id | parent_id | name | lft | rgt | value |
| 24 | 23 | Administrator | 15 | 18 | Administrator |
| 25 | 24 | Super Administrator | 16 | 17 | Super Administrator |
[/code:1]

So the u.gid >=24 is referring to all users which belong to the group with an ID of 24 or higher, which in standard cases would be the Administrators and the Super Administrators.

Stephan
Page: 1