svn: /web/php-master/trunk/ entry/user-note.php scripts/update-user-notes
| From: | Daniel P. Brown | Date: | Tue, 10 Jan 2012 19:41:33 +0000 |
| Subject: | svn: /web/php-master/trunk/ entry/user-note.php scripts/update-user-notes | ||
| Groups: | php.webmaster | ||
| Request: | Send a blank email to php-webmaster+get-12770@lists.php.net to get a copy of this message | ||
danbrown Tue, 10 Jan 2012 19:41:33 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=322031
Log:
Seeing Philip's discussion on IRC just now regarding ereg* functions reminded me to commit
this. Been sitting on it for a year or more.
Changed paths:
U web/php-master/trunk/entry/user-note.php
U web/php-master/trunk/scripts/update-user-notes
Modified: web/php-master/trunk/entry/user-note.php
===================================================================
--- web/php-master/trunk/entry/user-note.php 2012-01-10 18:35:14 UTC (rev 322030)
+++ web/php-master/trunk/entry/user-note.php 2012-01-10 19:41:33 UTC (rev 322031)
@@ -87,7 +87,7 @@
if ($count >= 3) {
//Send error to myself. If this happens too many times, I'll increase
//the amount of allowed notes
- mail ('alindeman@php.net,didou@php.net',
+ mail ('alindeman@php.net,didou@php.net,danbrown@php.net',
'[php-notes] Quota exceeded',
'Too many notes submitted in one minute. Consider increasing quota' . "\n" .
'Occured at '.date ('M d, Y g:i:s A') . "\n" .
@@ -100,7 +100,7 @@
die ('[TOO MANY NOTES]');
}
-$sect = trim(ereg_replace("\.php$","",$sect));
+$sect = trim(preg_replace('/\.php$/','',$sect));
$query = "INSERT INTO note (user, note, sect, ts, status) VALUES ";
# no need to call htmlspecialchars() -- we handle it on output
Modified: web/php-master/trunk/scripts/update-user-notes
===================================================================
--- web/php-master/trunk/scripts/update-user-notes 2012-01-10 18:35:14 UTC (rev 322030)
+++ web/php-master/trunk/scripts/update-user-notes 2012-01-10 19:41:33 UTC (rev 322031)
@@ -15,7 +15,7 @@
$token = rawurlencode($token);
$root = $argv[1];
-if (!ereg("/\$",$root)) {
+if (substr($root,-1)) {
$root = "$root/";
}
$since = $argv[2];