Completed
Push — master ( 182b8c...09455a )
by Thomas
07:02
created
htdocs/editdesc.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -9,20 +9,20 @@  discard block
 block discarded – undo
9 9
  *  Unicode Reminder メモ
10 10
  *****************************************************************************/
11 11
 
12
-require_once __DIR__ . '/lib/consts.inc.php';
12
+require_once __DIR__.'/lib/consts.inc.php';
13 13
 $opt['gui'] = GUI_HTML;
14
-require_once __DIR__ . '/lib/common.inc.php';
15
-require_once __DIR__ . '/lib2/edithelper.inc.php';
14
+require_once __DIR__.'/lib/common.inc.php';
15
+require_once __DIR__.'/lib2/edithelper.inc.php';
16 16
 
17 17
 // Preprocessing
18 18
 if ($error == false) {
19
-    require $stylepath . '/editdesc.inc.php';
19
+    require $stylepath.'/editdesc.inc.php';
20 20
 
21 21
     // check for old-style parameters
22 22
     if (isset($_REQUEST['cacheid']) && isset($_REQUEST['desclang']) && !isset($_REQUEST['descid']))  // Ocprop
23 23
     {
24
-        $cache_id = $_REQUEST['cacheid'];  // Ocprop
25
-        $desc_lang = $_REQUEST['desclang'];  // Ocprop
24
+        $cache_id = $_REQUEST['cacheid']; // Ocprop
25
+        $desc_lang = $_REQUEST['desclang']; // Ocprop
26 26
 
27 27
         $rs = sql("SELECT `id` FROM `cache_desc` WHERE `cache_id`='&1' AND `language`='&2'", $cache_id, $desc_lang);
28 28
         if (mysql_num_rows($rs) == 1) {
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
         $tplname = 'login';
44 44
 
45 45
         tpl_set_var('username', '');
46
-        tpl_set_var('target', htmlspecialchars('editdesc.php?descid=' . urlencode($descid), ENT_COMPAT, 'UTF-8'));
46
+        tpl_set_var('target', htmlspecialchars('editdesc.php?descid='.urlencode($descid), ENT_COMPAT, 'UTF-8'));
47 47
         tpl_set_var('message_start', "");
48 48
         tpl_set_var('message_end', "");
49 49
         tpl_set_var('message', $login_required);
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
                 if (isset($_POST['post']))  // Ocprop
91 91
                 {
92 92
                     //here we read all used information from the form if submitted
93
-                    $descMode = isset($_POST['descMode']) ? $_POST['descMode'] + 0 : 1;  // Ocprop
93
+                    $descMode = isset($_POST['descMode']) ? $_POST['descMode'] + 0 : 1; // Ocprop
94 94
 
95 95
                     // fuer alte Versionen von OCProp
96 96
                     if (isset($_POST['submit']) && !isset($_POST['version2'])) {
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
                         $oldDescMode = $descMode;
124 124
                     }
125 125
 
126
-                    $short_desc = $_POST['short_desc'];  // Ocprop
126
+                    $short_desc = $_POST['short_desc']; // Ocprop
127 127
                     $hint = htmlspecialchars($_POST['hints'], ENT_COMPAT, 'UTF-8');
128 128
                     $desclang = $_POST['desclang'];
129 129
                     $show_all_langs = isset($_POST['show_all_langs_value']) ? $_POST['show_all_langs_value'] : 0;
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
                     }
139 139
 
140 140
                     // Text from textarea
141
-                    $desc = $_POST['desc'];  // Ocprop
141
+                    $desc = $_POST['desc']; // Ocprop
142 142
 
143 143
                     // fuer alte Versionen von OCProp
144 144
                     if (isset($_POST['submit']) && !isset($_POST['version2'])) {
@@ -207,7 +207,7 @@  discard block
 block discarded – undo
207 207
                         db_slave_exclude();
208 208
 
209 209
                         // redirect to cachepage
210
-                        tpl_redirect('editcache.php?cacheid=' . urlencode($desc_record['cache_id']));
210
+                        tpl_redirect('editcache.php?cacheid='.urlencode($desc_record['cache_id']));
211 211
                         exit;
212 212
                     } elseif (isset($_POST['show_all_langs'])) {
213 213
                         $show_all_langs = true;
@@ -277,7 +277,7 @@  discard block
 block discarded – undo
277 277
                     ($show_all_langs == true) ? 1 : 0);
278 278
                 while ($rLanguage = sql_fetch_assoc($rsLanguages)) {
279 279
                     $sSelected = ($rLanguage['short'] == $desc_lang) ? ' selected="selected"' : '';
280
-                    $languages .= '<option value="' . $rLanguage['short'] . '"' . $sSelected . '>' . htmlspecialchars($rLanguage['name'], ENT_COMPAT, 'UTF-8') . '</option>' . "\n";
280
+                    $languages .= '<option value="'.$rLanguage['short'].'"'.$sSelected.'>'.htmlspecialchars($rLanguage['name'], ENT_COMPAT, 'UTF-8').'</option>'."\n";
281 281
                 }
282 282
                 sql_free_result($rsLanguages);
283 283
 
@@ -297,20 +297,20 @@  discard block
 block discarded – undo
297 297
                 tpl_set_var('desclang', htmlspecialchars($desc_lang, ENT_COMPAT, 'UTF-8'));
298 298
                 tpl_set_var('desclang_name', htmlspecialchars(db_LanguageFromShort($desc_lang), ENT_COMPAT, 'UTF-8'));
299 299
                 tpl_set_var('cachename', htmlspecialchars($desc_record['name'], ENT_COMPAT, 'UTF-8'));
300
-                tpl_set_var('reset', $reset);  // obsolete
300
+                tpl_set_var('reset', $reset); // obsolete
301 301
                 tpl_set_var('submit', $submit);
302 302
 
303 303
                 // Text / normal HTML / HTML editor
304 304
                 tpl_set_var('use_tinymce', ($desc_htmledit == 1) ? 1 : 0);
305 305
 
306
-                $headers = tpl_get_var('htmlheaders') . "\n";
306
+                $headers = tpl_get_var('htmlheaders')."\n";
307 307
                 if (($desc_html == 1) && ($desc_htmledit == 1)) {
308 308
                     // TinyMCE
309
-                    $headers = tpl_get_var('htmlheaders') . "\n";
310
-                    $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/tiny_mce_gzip.js"></script>' . "\n";
311
-                    $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/config/desc.js.php?cacheid=' . ($desc_record['cache_id'] + 0) . '&lang=' . strtolower($locale) . '"></script>' . "\n";
309
+                    $headers = tpl_get_var('htmlheaders')."\n";
310
+                    $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/tiny_mce_gzip.js"></script>'."\n";
311
+                    $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/config/desc.js.php?cacheid='.($desc_record['cache_id'] + 0).'&lang='.strtolower($locale).'"></script>'."\n";
312 312
                 }
313
-                $headers .= '<script language="javascript" type="text/javascript" src="' . editorJsPath() . '"></script>' . "\n";
313
+                $headers .= '<script language="javascript" type="text/javascript" src="'.editorJsPath().'"></script>'."\n";
314 314
                 tpl_set_var('htmlheaders', $headers);
315 315
             } else {
316 316
                 // @todo: not the owner
Please login to merge, or discard this patch.
htdocs/adminreports.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@  discard block
 block discarded – undo
5 5
  *  Unicode Reminder メモ
6 6
  ***************************************************************************/
7 7
 
8
-require __DIR__ . '/lib2/web.inc.php';
8
+require __DIR__.'/lib2/web.inc.php';
9 9
 
10 10
 $tpl->name = 'adminreports';
11 11
 $tpl->menuitem = MNU_ADMIN_REPORTS;
@@ -43,15 +43,15 @@  discard block
 block discarded – undo
43 43
     ($adminid == 0 || ($adminid != $login->userid && $age >= 14))
44 44
 ) {
45 45
     sql("UPDATE `cache_reports` SET `status`=2, `adminid`=&2 WHERE `id`=&1", $rid, $login->userid);
46
-    $tpl->redirect('adminreports.php?id=' . $rid);
46
+    $tpl->redirect('adminreports.php?id='.$rid);
47 47
 } elseif (isset($_REQUEST['contact']) && $ownerid > 0) {
48 48
     $wp_oc = sql_value("SELECT `wp_oc` FROM `caches` WHERE `cache_id`='&1'", '', $cacheid);
49
-    $tpl->redirect('mailto.php?userid=' . urlencode($ownerid) . '&wp=' . $wp_oc);
49
+    $tpl->redirect('mailto.php?userid='.urlencode($ownerid).'&wp='.$wp_oc);
50 50
 } elseif (isset($_REQUEST['contact_reporter']) && $reporterid > 0) {
51
-    $tpl->redirect('mailto.php?userid=' . urlencode($reporterid) . '&reportid=' . $rid);
51
+    $tpl->redirect('mailto.php?userid='.urlencode($reporterid).'&reportid='.$rid);
52 52
 } elseif (isset($_REQUEST['done']) && $adminid == $login->userid) {
53 53
     sql("UPDATE `cache_reports` SET `status`=3 WHERE `id`=&1", $rid);
54
-    $tpl->redirect('adminreports.php?id=' . $rid);
54
+    $tpl->redirect('adminreports.php?id='.$rid);
55 55
 } elseif (isset($_REQUEST['assign']) && ($adminid == 0 || $adminid != $login->userid)) {
56 56
     $error = 1;
57 57
     $id = 0;
Please login to merge, or discard this patch.
htdocs/event_attendance.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
  *  Unicode Reminder メモ
6 6
  ***************************************************************************/
7 7
 
8
-require __DIR__ . '/lib2/web.inc.php';
8
+require __DIR__.'/lib2/web.inc.php';
9 9
 
10 10
 $tpl->name = 'event_attendance';
11 11
 $tpl->popup = true;
Please login to merge, or discard this patch.
local/maintenance/update_passwords.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -8,9 +8,9 @@
 block discarded – undo
8 8
  ***************************************************************************/
9 9
 
10 10
 global $opt;
11
-$opt['rootpath'] = __DIR__ . '/../../htdocs/';
12
-require $opt['rootpath'] . 'lib2/cli.inc.php';
13
-require $opt['rootpath'] . 'lib2/logic/crypt.class.php';
11
+$opt['rootpath'] = __DIR__.'/../../htdocs/';
12
+require $opt['rootpath'].'lib2/cli.inc.php';
13
+require $opt['rootpath'].'lib2/logic/crypt.class.php';
14 14
 
15 15
 if (!isset($opt['logic']['password_salt']) || strlen($opt['logic']['password_salt']) < 32) {
16 16
     echo "Warning!\nPassword Salt not set or too short!\n\n";
Please login to merge, or discard this patch.
local/maintenance/update_queries.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
  ***************************************************************************/
10 10
 
11 11
 $opt['rootpath'] = '../../htdocs/';
12
-require $opt['rootpath'] . 'lib2/web.inc.php';
12
+require $opt['rootpath'].'lib2/web.inc.php';
13 13
 
14 14
 if ($argc != 2 || $argv[1] != 'go') {
15 15
     die("run with parameter 'go' to update queries\n");
@@ -22,15 +22,15 @@  discard block
 block discarded – undo
22 22
         $cachesize = $query['cachesize'];
23 23
 
24 24
         // add nano size to all queries that include micro or other
25
-        if (preg_match('/[;][12][;]/', ';' . $cachesize . ';') &&
26
-            !preg_match('/[;][8][;]/', ';' . $cachesize . ';')
25
+        if (preg_match('/[;][12][;]/', ';'.$cachesize.';') &&
26
+            !preg_match('/[;][8][;]/', ';'.$cachesize.';')
27 27
         ) {
28 28
             // echo $r['name'] . ": " . $cachesize . " -> " . $query['cachesize'] .= ";8\n";
29 29
             $query['cachesize'] .= ';8';
30 30
             $saveopt = serialize($query);
31 31
             // sql("UPDATE queries SET `options`='&1' WHERE `id`='&2'", $saveopt, $r['id']);
32 32
             // ^^ run this line only if you are absolutely sure what you are doing
33
-            echo 'added nano to query ' . $r['id'] . "(" . $cachesize . ') of user ' . $r['user_id'] . "\n";
33
+            echo 'added nano to query '.$r['id']."(".$cachesize.') of user '.$r['user_id']."\n";
34 34
         }
35 35
     }
36 36
 }
Please login to merge, or discard this patch.
local/maintenance/email_recovery.php 1 patch
Spacing   +37 added lines, -37 removed lines patch added patch discarded remove patch
@@ -16,25 +16,25 @@  discard block
 block discarded – undo
16 16
  *  Unicode Reminder メモ
17 17
  ***************************************************************************/
18 18
 
19
-$opt['rootpath'] = __DIR__ . '/../../htdocs/';
20
-require $opt['rootpath'] . 'lib2/cli.inc.php';
19
+$opt['rootpath'] = __DIR__.'/../../htdocs/';
20
+require $opt['rootpath'].'lib2/cli.inc.php';
21 21
 
22 22
 if ($argc < 3 || $argc > 4) {
23 23
     die(
24
-        "usage:    php email_recovery.php \"from-datetime\" \"to-datetime\" [option]\n" .
25
-        "\n" .
26
-        "          Datetimes must be in YYYY-MM-DD HH:MM:SS format and are inclusive.\n" .
27
-        "\n" .
28
-        "options:  <none>          show information about all lost information\n" .
29
-        "          watchlist       resend log notifications\n" .
30
-        "          newcaches       resend new caches notifications\n" .
24
+        "usage:    php email_recovery.php \"from-datetime\" \"to-datetime\" [option]\n".
25
+        "\n".
26
+        "          Datetimes must be in YYYY-MM-DD HH:MM:SS format and are inclusive.\n".
27
+        "\n".
28
+        "options:  <none>          show information about all lost information\n".
29
+        "          watchlist       resend log notifications\n".
30
+        "          newcaches       resend new caches notifications\n".
31 31
         "          registrations   resend activation codes\n"
32 32
     );
33 33
 }
34 34
 
35 35
 $er = new EmailRecovery($argv[1], $argv[2], $errormsg);
36 36
 if ($errormsg != '') {
37
-    die($errormsg . "\n");
37
+    die($errormsg."\n");
38 38
 }
39 39
 
40 40
 if ($argc < 4) {
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
             $er->resendActivationCodes();
53 53
             break;
54 54
         default:
55
-            die('invalid option: '. $option . "\n");
55
+            die('invalid option: '.$option."\n");
56 56
     }
57 57
 }
58 58
 
@@ -65,9 +65,9 @@  discard block
 block discarded – undo
65 65
     public function __construct($fromDT, $toDT, &$errormsg)
66 66
     {
67 67
         if (!self::verifyDateTime($fromDT)) {
68
-            $errormsg = 'invalid from-datetime (must be SQL format): "' . $fromDT . '"';
68
+            $errormsg = 'invalid from-datetime (must be SQL format): "'.$fromDT.'"';
69 69
         } elseif (!self::verifyDateTime($toDT)) {
70
-            $errormsg = 'invalid from-datetime (must be SQL format): "' . $toDT . '"';
70
+            $errormsg = 'invalid from-datetime (must be SQL format): "'.$toDT.'"';
71 71
         } else {
72 72
             $this->fromDateTime = $fromDT;
73 73
             $this->toDateTime = $toDT;
@@ -85,26 +85,26 @@  discard block
 block discarded – undo
85 85
 
86 86
     private static function message($level, $text)
87 87
     {
88
-        echo str_repeat(' ', 2 * $level) . $text . "\n";
88
+        echo str_repeat(' ', 2 * $level).$text."\n";
89 89
     }
90 90
 
91 91
     private function getDateCondition($table, $field)
92 92
     {
93 93
         return
94
-            "`" . $table . "`.`" . $field . "` >= '" . sql_escape($this->fromDateTime) . "'" .
95
-            " AND `" . $table . "`.`" . $field . "` <= '" . sql_escape($this->toDateTime) . "'";
94
+            "`".$table."`.`".$field."` >= '".sql_escape($this->fromDateTime)."'".
95
+            " AND `".$table."`.`".$field."` <= '".sql_escape($this->toDateTime)."'";
96 96
     }
97 97
 
98 98
     private function showObjectCount($table, $dateField, $description, $andWhere = '')
99 99
     {
100 100
         $objectCount = sql_value(
101 101
             "SELECT COUNT(*)
102
-             FROM `" . $table . "`
103
-             WHERE " . $this->getDateCondition($table, $dateField) .
104
-                       ($andWhere ? ' AND (' . $andWhere . ')' : ''),
102
+             FROM `" . $table."`
103
+             WHERE " . $this->getDateCondition($table, $dateField).
104
+                       ($andWhere ? ' AND ('.$andWhere.')' : ''),
105 105
             0
106 106
         );
107
-        self::message(1, $objectCount . ' ' . $description);
107
+        self::message(1, $objectCount.' '.$description);
108 108
     }
109 109
 
110 110
 
@@ -153,16 +153,16 @@  discard block
 block discarded – undo
153 153
              JOIN `user` `user1` ON `user1`.`user_id` = `cache_logs_archived`.`user_id`
154 154
              JOIN `user` `user2` ON `user2`.`user_id` = `cache_logs_archived`.`deleted_by`
155 155
              JOIN `caches` ON `caches`.`cache_id` = `cache_logs_archived`.`cache_id`
156
-             WHERE " . $this->getDateCondition('cache_logs_archived', 'deletion_date') . "
156
+             WHERE " . $this->getDateCondition('cache_logs_archived', 'deletion_date')."
157 157
              ORDER BY `cache_logs_archived`.`deletion_date` DESC"
158 158
         );
159 159
         while ($r = sql_fetch_assoc($rs)) {
160 160
             self::message(
161 161
                 2,
162 162
                 $r['wp_oc']
163
-                . ' logged:' . $r['logdate']
164
-                . ' logger:' . $r['logger_name']
165
-                . ' deleter:' . $r['deleter_name']
163
+                . ' logged:'.$r['logdate']
164
+                . ' logger:'.$r['logger_name']
165
+                . ' deleter:'.$r['deleter_name']
166 166
             );
167 167
         }
168 168
         sql_free_result($rs);
@@ -175,12 +175,12 @@  discard block
 block discarded – undo
175 175
                 `username`
176 176
              FROM `user`
177 177
              WHERE " .
178
-                $this->getDateCondition('user', 'date_created') . "
178
+                $this->getDateCondition('user', 'date_created')."
179 179
                 AND last_login IS NULL AND `activation_code` <> ''
180 180
              ORDER BY `date_created` DESC"
181 181
         );
182 182
         while ($r = sql_fetch_assoc($rs)) {
183
-            self::message(2, $r['registration_date'] . ' ' . $r['username']);
183
+            self::message(2, $r['registration_date'].' '.$r['username']);
184 184
         }
185 185
         sql_free_result($rs);
186 186
 
@@ -192,11 +192,11 @@  discard block
 block discarded – undo
192 192
                 `user`.`username` `sender_name`
193 193
              FROM `email_user`
194 194
              JOIN `user` ON `user`.`user_id` = `email_user`.`from_user_id`
195
-             WHERE " . $this->getDateCondition('email_user', 'date_created') . "
195
+             WHERE " . $this->getDateCondition('email_user', 'date_created')."
196 196
              ORDER BY `email_user`.`date_created` DESC"
197 197
         );
198 198
         while ($r = sql_fetch_assoc($rs)) {
199
-            self::message(2, $r['emaildate'] . ' from:' . $r['sender_name']);
199
+            self::message(2, $r['emaildate'].' from:'.$r['sender_name']);
200 200
         }
201 201
         sql_free_result($rs);
202 202
     }
@@ -232,7 +232,7 @@  discard block
 block discarded – undo
232 232
                 JOIN `cache_status` ON `cache_status`.`id` = `caches`.`status`
233 233
                 JOIN `cache_watches` ON `cache_watches`.`cache_id` = `caches`.`cache_id`
234 234
                 WHERE
235
-                    " . $this->getDateCondition('cache_logs', 'date_created') . "
235
+                    " . $this->getDateCondition('cache_logs', 'date_created')."
236 236
                     AND `cache_status`.`allow_user_view` = 1"
237 237
         );
238 238
         $watcher_notifications = sql_affected_rows();
@@ -247,13 +247,13 @@  discard block
 block discarded – undo
247 247
                 JOIN `cache_list_items` ON `cache_list_items`.`cache_id` = `cache_logs`.`cache_id`
248 248
                 JOIN `cache_list_watches` ON `cache_list_watches`.`cache_list_id` = `cache_list_items`.`cache_list_id`
249 249
                 WHERE
250
-                    " . $this->getDateCondition('cache_logs', 'date_created') . "
250
+                    " . $this->getDateCondition('cache_logs', 'date_created')."
251 251
                     AND `cache_status`.`allow_user_view` = 1"
252 252
         );
253 253
         $watcher_notifications += sql_affected_rows();
254 254
 
255
-        self::message(0, $owner_notifications . ' owners will be notified');
256
-        self::message(0, $watcher_notifications . ' watchers will be notified');
255
+        self::message(0, $owner_notifications.' owners will be notified');
256
+        self::message(0, $watcher_notifications.' watchers will be notified');
257 257
     }
258 258
 
259 259
     public function resendCacheNotifications()
@@ -265,7 +265,7 @@  discard block
 block discarded – undo
265 265
              FROM `caches`
266 266
              JOIN `cache_status` ON `cache_status`.`id` = `caches`.`status`
267 267
              WHERE
268
-                " . $this->getDateCondition('caches', 'date_created') . "
268
+                " . $this->getDateCondition('caches', 'date_created')."
269 269
                 AND `cache_status`.`allow_user_view` = 1"
270 270
         );
271 271
         while ($r = sql_fetch_assoc($rs)) {
@@ -280,7 +280,7 @@  discard block
 block discarded – undo
280 280
 
281 281
         $new_notifications =
282 282
             sql_value("SELECT COUNT(*) FROM `notify_waiting`", 0) - $notifies_wating;
283
-        self::message(0, $new_notifications . ' new cache notifications will be sent');
283
+        self::message(0, $new_notifications.' new cache notifications will be sent');
284 284
     }
285 285
     
286 286
     public function resendActivationCodes()
@@ -289,7 +289,7 @@  discard block
 block discarded – undo
289 289
             "SELECT `user_id`
290 290
              FROM `user`
291 291
              WHERE
292
-                " . $this->getDateCondition('user', 'date_created') . "
292
+                " . $this->getDateCondition('user', 'date_created')."
293 293
                 AND last_login IS NULL
294 294
                 AND `activation_code` <> ''"
295 295
         );
@@ -297,10 +297,10 @@  discard block
 block discarded – undo
297 297
         while ($r = sql_fetch_assoc($rs)) {
298 298
             $user = new user($r['user_id']);
299 299
             $user->sendRegistrationCode();
300
-            ++ $n;
300
+            ++$n;
301 301
         }
302 302
         sql_free_result($rs);
303
-        self::message(0, $n . ' users have been re-sent the activation code');
303
+        self::message(0, $n.' users have been re-sent the activation code');
304 304
     }
305 305
     
306 306
 }
Please login to merge, or discard this patch.
local/maintenance/init_user_languages.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -8,9 +8,9 @@  discard block
 block discarded – undo
8 8
  *  Unicode Reminder メモ
9 9
  ***************************************************************************/
10 10
 
11
-$opt['rootpath'] = __DIR__ . '/../../htdocs/';
12
-require_once $opt['rootpath'] . 'lib2/cli.inc.php';
13
-require_once $opt['rootpath'] . 'lib2/logic/user.class.php';
11
+$opt['rootpath'] = __DIR__.'/../../htdocs/';
12
+require_once $opt['rootpath'].'lib2/cli.inc.php';
13
+require_once $opt['rootpath'].'lib2/logic/user.class.php';
14 14
 
15 15
 $write = ($argc == 2 && $argv[1] = 'write');
16 16
 if (!$write) {
@@ -31,11 +31,11 @@  discard block
 block discarded – undo
31 31
                 $lang
32 32
             );
33 33
         }
34
-        ++ $set;
34
+        ++$set;
35 35
     }
36
-    if (++ $processed % 1000 == 0) {
37
-        echo "$set of $processed " . ($write ? '' : 'would be ') . "set\n";
36
+    if (++$processed % 1000 == 0) {
37
+        echo "$set of $processed ".($write ? '' : 'would be ')."set\n";
38 38
     }
39 39
 }
40
-echo "$set of $processed " . ($write ? '' : 'would be ') . "set\n";
40
+echo "$set of $processed ".($write ? '' : 'would be ')."set\n";
41 41
 sql_free_result($rs);
Please login to merge, or discard this patch.
local/maintenance/cleanup_coordinates.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -12,8 +12,8 @@  discard block
 block discarded – undo
12 12
  *  Unicode Reminder メモ
13 13
  ***************************************************************************/
14 14
 
15
-$opt['rootpath'] = __DIR__ . '/../../htdocs/';
16
-require $opt['rootpath'] . 'lib2/cli.inc.php';
15
+$opt['rootpath'] = __DIR__.'/../../htdocs/';
16
+require $opt['rootpath'].'lib2/cli.inc.php';
17 17
 
18 18
 $rs = sql(
19 19
     "SELECT `id`, `cache_id`, `latitude`, `longitude`
@@ -41,14 +41,14 @@  discard block
 block discarded – undo
41 41
 
42 42
 if ($duplicates) {
43 43
     if ($argc == 2 && $argv[1] == 'go') {
44
-        echo 'deleting ' . count($duplicates) . " duplicate coordinate records\n";
44
+        echo 'deleting '.count($duplicates)." duplicate coordinate records\n";
45 45
         sql(
46 46
             "DELETE FROM `cache_coordinates`
47
-             WHERE `id` IN (" . implode(',', $duplicates) . ")"
47
+             WHERE `id` IN (" . implode(',', $duplicates).")"
48 48
         );
49 49
     } else {
50 50
         echo
51
-            count($duplicates) . ' duplicate coordinates found. ' .
51
+            count($duplicates).' duplicate coordinates found. '.
52 52
             "Add parameter 'go' to delete them.\n";
53 53
     }
54 54
 } else {
Please login to merge, or discard this patch.
local/mailing/email-addresslist.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -7,8 +7,8 @@  discard block
 block discarded – undo
7 7
 
8 8
 header('Content-type: text/html; charset=utf-8');
9 9
 
10
-$opt['rootpath'] = __DIR__ . '/../../htdocs/';
11
-require $opt['rootpath'] . 'lib2/web.inc.php';
10
+$opt['rootpath'] = __DIR__.'/../../htdocs/';
11
+require $opt['rootpath'].'lib2/web.inc.php';
12 12
 
13 13
 $rs = sql(
14 14
     'SELECT email FROM `user`
@@ -18,6 +18,6 @@  discard block
 block discarded – undo
18 18
      ORDER BY user_id DESC'
19 19
 );
20 20
 while ($r = sql_fetch_assoc($rs)) {
21
-    echo $r['email'] . "\n";
21
+    echo $r['email']."\n";
22 22
 }
23 23
 sql_free_result($rs);
Please login to merge, or discard this patch.