Mcfarlin Posted December 11, 2009 Posted December 11, 2009 okay anyone else tiered of not getting a new mail notification when one is sent out as a mass mail? i know this isnt much other than a VERY small fix. in yourgang.php find [mysql]$db->query("INSERT INTO mail VALUES('', 0, {$ir['userid']}, {$r['userid']}, unix_timestamp(),'$subj','{$_POST['text']}')");[/mysql] and right after it simply add [mysql]$db->query("UPDATE users SET new_mail=new_mail+1 WHERE gang={$ir['gang']}");[/mysql] remember guys not everyone here KNOWS how to code, this is just a little something for those who want it. Quote
Nicholas Posted December 13, 2009 Posted December 13, 2009 RE: mass mail notification okay anyone else tiered of not getting a new mail notification when one is sent out as a mass mail? i know this isnt much other than a VERY small fix. in yourgang.php find [mysql]$db->query("INSERT INTO mail VALUES('', 0, {$ir['userid']}, {$r['userid']}, unix_timestamp(),'$subj','{$_POST['text']}')");[/mysql] and right after it simply add [mysql]$db->query("UPDATE users SET new_mail=new_mail+1 WHERE gang={$ir['gang']}");[/mysql] remember guys not everyone here KNOWS how to code, this is just a little something for those who want it. acturally you wanna use You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. if you use that one and say you got like 5 members in your gang, your mailbox be Mailbox (5) Quote
Jordan Palmer Posted December 18, 2009 Posted December 18, 2009 I never even noticed people don't get a notification lol - But good work :) Quote
Mcfarlin Posted December 20, 2009 Author Posted December 20, 2009 i have images for the most of the links on the main menu i never looked to see if it updated it with more than one. mine no longer shows how many new mails you have. <----like this for new mails, and for no new mails. :D Quote
Equinox Posted December 20, 2009 Posted December 20, 2009 I haven't actually viewed the code for Mccodes yet, but I doubt it's got a secure class. Try this code: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. I don't know if that will help at all :) If anyone could help me get to grips with Mccodes though, that'd be great :thumbup: Quote
Danny696 Posted December 20, 2009 Posted December 20, 2009 Unless you have addslashes($_POST['text']) then theres no need to strip them. Quote
Equinox Posted December 21, 2009 Posted December 21, 2009 Unless you have addslashes($_POST['text']) then theres no need to strip them. Erm.... mysql_real_escape_string() strips special characters that may be entered And the strip_tags() strips any PHP or HTML tags that are entered..... I'm cleaning the entered text before it's inserted into the database. Quote
Equinox Posted December 21, 2009 Posted December 21, 2009 my bad, thought it said addslashes :rolleyes: Quote
Zero-Affect Posted December 30, 2009 Posted December 30, 2009 but would you clean it when pulling from DB? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.