diff options
author | Bot <bot@myigel.name> | 2017-01-03 14:12:17 +0100 |
---|---|---|
committer | Igor Scheller <igor.scheller@igorshp.de> | 2017-01-03 15:32:59 +0100 |
commit | 55141154c083acc2d0397f4c62b4e0be1c7a19fa (patch) | |
tree | 7e5e54a19f7df976fa68c42f21f1484112a7c257 /includes/model/LogEntries_model.php | |
parent | 356b2582f3e6a43ecf2607acad4a7fe0b37f659a (diff) |
Replaced " with '
Diffstat (limited to 'includes/model/LogEntries_model.php')
-rw-r--r-- | includes/model/LogEntries_model.php | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/includes/model/LogEntries_model.php b/includes/model/LogEntries_model.php index 7bcb868e..920b1945 100644 --- a/includes/model/LogEntries_model.php +++ b/includes/model/LogEntries_model.php @@ -9,7 +9,13 @@ */ function LogEntry_create($nick, $message) { - return sql_query("INSERT INTO `LogEntries` SET `timestamp`='" . sql_escape(time()) . "', `nick`='" . sql_escape($nick) . "', `message`='" . sql_escape($message) . "'"); + return sql_query(" + INSERT INTO `LogEntries` + SET + `timestamp`='" . sql_escape(time()) . "', + `nick`='" . sql_escape($nick) . "', + `message`='" . sql_escape($message) . "' + "); } /** @@ -19,7 +25,7 @@ function LogEntry_create($nick, $message) */ function LogEntries() { - return sql_select("SELECT * FROM `LogEntries` ORDER BY `timestamp` DESC LIMIT 10000"); + return sql_select('SELECT * FROM `LogEntries` ORDER BY `timestamp` DESC LIMIT 10000'); } /** @@ -30,10 +36,16 @@ function LogEntries() */ function LogEntries_filter($keyword) { - if ($keyword == "") { + if ($keyword == '') { return LogEntries(); } - return sql_select("SELECT * FROM `LogEntries` WHERE `nick` LIKE '%" . sql_escape($keyword) . "%' OR `message` LIKE '%" . sql_escape($keyword) . "%' ORDER BY `timestamp` DESC"); + return sql_select(" + SELECT * + FROM `LogEntries` + WHERE `nick` LIKE '%" . sql_escape($keyword) . "%' + OR `message` LIKE '%" . sql_escape($keyword) . "%' + ORDER BY `timestamp` DESC + "); } /** @@ -43,5 +55,5 @@ function LogEntries_filter($keyword) */ function LogEntries_clear_all() { - return sql_query("TRUNCATE `LogEntries`"); + return sql_query('TRUNCATE `LogEntries`'); } |