MyBB Community Forums

Full Version: Receive emails from administrator - Kind of Important!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi guys I have removed this option from register template my question is if this option is removed then what value is send to SQL 0 or 1? I am not sure but I think that default value is 0 then how can I change it to 1???
Matt in Common SQL queries Wrote:Set all people to recieve admin emails (requires template changes to remove option to change again):
UPDATE `mybb_users` SET `allownotices` = '1' WHERE `allownotices` = '0' 
If the default is 0 then you can either do an <input type="hidden" ... value="1"/> instead of the checkbox, OR change the user datahandler to always have it set to 1, OR change the sending email feature to not check if the value is set.
Guys thanks very much! I can't use hidden code because anyone with firebug will be able to change it. I just want to change the default value for "Receive emails from administrator" because after I removed this option all the new users have this option unchecked means that default value is set to 0
(2013-12-16, 03:24 PM)marcus123 Wrote: [ -> ]Guys thanks very much! I can't use hidden code because anyone with firebug will be able to change it. I just want to change the default value for "Receive emails from administrator" because after I removed this option all the new users have this option unchecked means that default value is set to 0

If someone wants to they can just add the code you removed via Firebug, too. You'd need to hard code the option in both member.php and usercp.php. That can get messy and makes upgrading harder. I'd say your best option is to use hidden inputs.
Thanks very much I will put the option back online and let users to decide!