if ($key == "result")
foreach($value['list'] as $r)
{
+
RPC_List::$user[] = $r;
if (strpos($r['user']['modes'],"o") !== false && strpos($r['user']['modes'],"S") == false)
RPC_List::$opercount++;
Message::Success("Deleted spamfilter entry: ".$r['name']." [type: ".$r['match_type']."] [targets: ".$r['spamfilter_targets']. "] [action: ".$r['ban_action']."] [reason: ".$r['reason']."] [set by: ".$r['set_by']."]");
}
return true;
+}
+
+/** Convert the duration_string */
+function rpc_convert_duration_string($str)
+{
+ $tok = explode("w", $str);
+ $weeks = $tok[0];
+ $tok = explode("d", $tok[1]);
+ $days = $tok[0];
+ $tok = explode("h", $tok[1]);
+ $hours = $tok[0];
+ return "$weeks weeks, $days days and $hours hours";
+
}
\ No newline at end of file