@@ -73,7 +73,7 @@ discard block |
||
| 73 | 73 | $name = _htmlspecialchars($row['firstname'] . ' ' . $row['lastname']); |
| 74 | 74 | } |
| 75 | 75 | |
| 76 | - $rows[] = [ |
|
| 76 | + $rows[] = [ |
|
| 77 | 77 | $name, |
| 78 | 78 | '<a href="mailto:' . $row['email'] . '">' . $row['email'] . '</a>', |
| 79 | 79 | $confirmed, |
@@ -81,7 +81,7 @@ discard block |
||
| 81 | 81 | ]; |
| 82 | 82 | } |
| 83 | 83 | |
| 84 | -$tabledata = [ |
|
| 84 | +$tabledata = [ |
|
| 85 | 85 | 'header' => [ |
| 86 | 86 | 'Name', |
| 87 | 87 | 'Email', |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | $max_time = relative_time($row['max_time']); |
| 21 | 21 | $min_time = str_replace(" ago", "", $min_time); |
| 22 | 22 | $max_time = str_replace(" ago", "", $max_time); |
| 23 | - $rows[] = [ |
|
| 23 | + $rows[] = [ |
|
| 24 | 24 | $row['count_ips'], |
| 25 | 25 | $row['group_count'], |
| 26 | 26 | '<a href="' . $row['url'] . '">' . _htmlentities($row['query']) . '</a>', |
@@ -29,7 +29,7 @@ discard block |
||
| 29 | 29 | ]; |
| 30 | 30 | } |
| 31 | 31 | |
| 32 | -$tabledata = [ |
|
| 32 | +$tabledata = [ |
|
| 33 | 33 | 'header' => [ |
| 34 | 34 | 'Distinct IPs', |
| 35 | 35 | 'Number of times', |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | |
| 10 | 10 | $EDITQUEUE = new \MySociety\TheyWorkForYou\GlossaryEditQueue(); |
| 11 | 11 | |
| 12 | -$args = [ |
|
| 12 | +$args = [ |
|
| 13 | 13 | 'sort' => "regexp_replace", |
| 14 | 14 | ]; |
| 15 | 15 | |
@@ -22,18 +22,18 @@ discard block |
||
| 22 | 22 | if (get_http_var('approve')) { |
| 23 | 23 | $approve = get_http_var('approve', '', true); |
| 24 | 24 | if (!is_array($approve)) { |
| 25 | - $approve = [ $approve ]; |
|
| 25 | + $approve = [$approve]; |
|
| 26 | 26 | } |
| 27 | 27 | // Add all approved items |
| 28 | - $data = [ |
|
| 28 | + $data = [ |
|
| 29 | 29 | 'approvals' => $approve, |
| 30 | 30 | 'epobject_type' => 2, |
| 31 | 31 | ]; |
| 32 | 32 | $EDITQUEUE->approve($data); |
| 33 | 33 | } elseif (get_http_var('decline')) { |
| 34 | - $decline = [get_http_var('decline')]; |
|
| 34 | + $decline = [get_http_var('decline')]; |
|
| 35 | 35 | // Dump all declined items |
| 36 | - $data = [ |
|
| 36 | + $data = [ |
|
| 37 | 37 | 'declines' => $decline, |
| 38 | 38 | 'epobject_type' => 2, |
| 39 | 39 | ]; |
@@ -59,7 +59,7 @@ |
||
| 59 | 59 | |
| 60 | 60 | $REPORT = new COMMENTREPORT(); |
| 61 | 61 | |
| 62 | - $reportdata = [ |
|
| 62 | + $reportdata = [ |
|
| 63 | 63 | 'body' => get_http_var('body'), |
| 64 | 64 | 'firstname' => get_http_var('firstname'), |
| 65 | 65 | 'lastname' => get_http_var('lastname'), |
@@ -70,7 +70,7 @@ |
||
| 70 | 70 | $URL->update(["gl" => $GLOSSARY->next_term['glossary_id']]); |
| 71 | 71 | $next_link = $URL->generate('url'); |
| 72 | 72 | |
| 73 | - $nextprev = [ |
|
| 73 | + $nextprev = [ |
|
| 74 | 74 | 'next' => [ |
| 75 | 75 | 'url' => $next_link, |
| 76 | 76 | 'title' => 'Next term', |
@@ -24,7 +24,7 @@ discard block |
||
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | function api_getComments_start_date($start_date) { |
| 27 | - $args = [ |
|
| 27 | + $args = [ |
|
| 28 | 28 | 'start_date' => $start_date, |
| 29 | 29 | 'end_date' => get_http_var('end_date'), |
| 30 | 30 | ]; |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | } |
| 34 | 34 | |
| 35 | 35 | function api_getComments_search($s) { |
| 36 | - $args = [ |
|
| 36 | + $args = [ |
|
| 37 | 37 | 's' => $s, |
| 38 | 38 | 'p' => get_http_var('page'), |
| 39 | 39 | 'num' => get_http_var('num'), |
@@ -354,8 +354,8 @@ |
||
| 354 | 354 | $out = "null"; |
| 355 | 355 | } elseif (is_string($v)) { |
| 356 | 356 | $out = '"' . str_replace( |
| 357 | - ["\\",'"',"\n","\t","\r", "‶", "″", "“", "”"], |
|
| 358 | - ["\\\\",'\"','\n','\t','\r', '\"', '\"', '\"', '\"'], |
|
| 357 | + ["\\", '"', "\n", "\t", "\r", "‶", "″", "“", "”"], |
|
| 358 | + ["\\\\", '\"', '\n', '\t', '\r', '\"', '\"', '\"', '\"'], |
|
| 359 | 359 | $v |
| 360 | 360 | ) . '"'; |
| 361 | 361 | } elseif (is_bool($v)) { |
@@ -1,7 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | function api_getAlerts_start_date($start_date) { |
| 4 | - $args = ['start_date' => $start_date, 'end_date' => get_http_var('end_date')]; |
|
| 4 | + $args = ['start_date' => $start_date, 'end_date' => get_http_var('end_date')]; |
|
| 5 | 5 | $alert = new ALERT(); |
| 6 | 6 | $data = $alert->fetch_between($confirmed = 1, $deleted = 0, $args['start_date'], $args['end_date']); |
| 7 | 7 | api_output($data); |
@@ -88,58 +88,58 @@ |
||
| 88 | 88 | function _api_ni_centroids() { |
| 89 | 89 | return [ |
| 90 | 90 | # East Londonderry |
| 91 | - 66129 => ['centre_lat' => 54.980766, 'centre_lon' => -6.904907 ], |
|
| 92 | - 14276 => ['centre_lat' => 54.980766, 'centre_lon' => -6.904907 ], |
|
| 91 | + 66129 => ['centre_lat' => 54.980766, 'centre_lon' => -6.904907], |
|
| 92 | + 14276 => ['centre_lat' => 54.980766, 'centre_lon' => -6.904907], |
|
| 93 | 93 | # Foyle |
| 94 | - 66131 => ['centre_lat' => 54.933453, 'centre_lon' => -7.267456 ], |
|
| 95 | - 14273 => ['centre_lat' => 54.933453, 'centre_lon' => -7.267456 ], |
|
| 94 | + 66131 => ['centre_lat' => 54.933453, 'centre_lon' => -7.267456], |
|
| 95 | + 14273 => ['centre_lat' => 54.933453, 'centre_lon' => -7.267456], |
|
| 96 | 96 | # West Tyrone |
| 97 | - 66141 => ['centre_lat' => 54.619797, 'centre_lon' => -7.410278 ], |
|
| 98 | - 14292 => ['centre_lat' => 54.619797, 'centre_lon' => -7.410278 ], |
|
| 97 | + 66141 => ['centre_lat' => 54.619797, 'centre_lon' => -7.410278], |
|
| 98 | + 14292 => ['centre_lat' => 54.619797, 'centre_lon' => -7.410278], |
|
| 99 | 99 | # Fermanagh & South Tyrone |
| 100 | - 14296 => ['centre_lat' => 54.354958, 'centre_lon' => -7.443237 ], |
|
| 101 | - 66130 => ['centre_lat' => 54.354958, 'centre_lon' => -7.443237 ], |
|
| 100 | + 14296 => ['centre_lat' => 54.354958, 'centre_lon' => -7.443237], |
|
| 101 | + 66130 => ['centre_lat' => 54.354958, 'centre_lon' => -7.443237], |
|
| 102 | 102 | # Newry & Armagh |
| 103 | - 14303 => ['centre_lat' => 54.297295, 'centre_lon' => -6.613770 ], |
|
| 104 | - 66134 => ['centre_lat' => 54.297295, 'centre_lon' => -6.613770 ], |
|
| 103 | + 14303 => ['centre_lat' => 54.297295, 'centre_lon' => -6.613770], |
|
| 104 | + 66134 => ['centre_lat' => 54.297295, 'centre_lon' => -6.613770], |
|
| 105 | 105 | # Upper Bann |
| 106 | - 14300 => ['centre_lat' => 54.399750, 'centre_lon' => -6.350098 ], |
|
| 107 | - 66140 => ['centre_lat' => 54.399750, 'centre_lon' => -6.350098 ], |
|
| 106 | + 14300 => ['centre_lat' => 54.399750, 'centre_lon' => -6.350098], |
|
| 107 | + 66140 => ['centre_lat' => 54.399750, 'centre_lon' => -6.350098], |
|
| 108 | 108 | # South Down |
| 109 | - 14306 => ['centre_lat' => 54.213860, 'centre_lon' => -6.152344 ], |
|
| 110 | - 66138 => ['centre_lat' => 54.213860, 'centre_lon' => -6.152344 ], |
|
| 109 | + 14306 => ['centre_lat' => 54.213860, 'centre_lon' => -6.152344], |
|
| 110 | + 66138 => ['centre_lat' => 54.213860, 'centre_lon' => -6.152344], |
|
| 111 | 111 | # Lagan Valley |
| 112 | - 14309 => ['centre_lat' => 54.441296, 'centre_lon' => -6.108398 ], |
|
| 113 | - 66132 => ['centre_lat' => 54.441296, 'centre_lon' => -6.108398 ], |
|
| 112 | + 14309 => ['centre_lat' => 54.441296, 'centre_lon' => -6.108398], |
|
| 113 | + 66132 => ['centre_lat' => 54.441296, 'centre_lon' => -6.108398], |
|
| 114 | 114 | # Strangford |
| 115 | - 14312 => ['centre_lat' => 54.514706, 'centre_lon' => -5.751343 ], |
|
| 116 | - 66139 => ['centre_lat' => 54.514706, 'centre_lon' => -5.751343 ], |
|
| 115 | + 14312 => ['centre_lat' => 54.514706, 'centre_lon' => -5.751343], |
|
| 116 | + 66139 => ['centre_lat' => 54.514706, 'centre_lon' => -5.751343], |
|
| 117 | 117 | # North Down |
| 118 | - 14325 => ['centre_lat' => 54.651592, 'centre_lon' => -5.718384 ], |
|
| 119 | - 66136 => ['centre_lat' => 54.651592, 'centre_lon' => -5.718384 ], |
|
| 118 | + 14325 => ['centre_lat' => 54.651592, 'centre_lon' => -5.718384], |
|
| 119 | + 66136 => ['centre_lat' => 54.651592, 'centre_lon' => -5.718384], |
|
| 120 | 120 | # South Antrim |
| 121 | - 14318 => ['centre_lat' => 54.699234, 'centre_lon' => -6.102905 ], |
|
| 122 | - 66137 => ['centre_lat' => 54.699234, 'centre_lon' => -6.102905 ], |
|
| 121 | + 14318 => ['centre_lat' => 54.699234, 'centre_lon' => -6.102905], |
|
| 122 | + 66137 => ['centre_lat' => 54.699234, 'centre_lon' => -6.102905], |
|
| 123 | 123 | # East Antrim |
| 124 | - 66128 => ['centre_lat' => 54.832336, 'centre_lon' => -5.883179 ], |
|
| 125 | - 14284 => ['centre_lat' => 54.832336, 'centre_lon' => -5.883179 ], |
|
| 124 | + 66128 => ['centre_lat' => 54.832336, 'centre_lon' => -5.883179], |
|
| 125 | + 14284 => ['centre_lat' => 54.832336, 'centre_lon' => -5.883179], |
|
| 126 | 126 | # North Antrim |
| 127 | - 66135 => ['centre_lat' => 54.993374, 'centre_lon' => -6.328125 ], |
|
| 128 | - 14280 => ['centre_lat' => 54.993374, 'centre_lon' => -6.328125 ], |
|
| 127 | + 66135 => ['centre_lat' => 54.993374, 'centre_lon' => -6.328125], |
|
| 128 | + 14280 => ['centre_lat' => 54.993374, 'centre_lon' => -6.328125], |
|
| 129 | 129 | # Mid Ulster |
| 130 | - 66133 => ['centre_lat' => 54.721447, 'centre_lon' => -6.795044 ], |
|
| 131 | - 14288 => ['centre_lat' => 54.721447, 'centre_lon' => -6.795044 ], |
|
| 130 | + 66133 => ['centre_lat' => 54.721447, 'centre_lon' => -6.795044], |
|
| 131 | + 14288 => ['centre_lat' => 54.721447, 'centre_lon' => -6.795044], |
|
| 132 | 132 | # Belfast North |
| 133 | - 14321 => ['centre_lat' => 54.618607, 'centre_lon' => -5.917511 ], |
|
| 134 | - 66125 => ['centre_lat' => 54.618607, 'centre_lon' => -5.917511 ], |
|
| 133 | + 14321 => ['centre_lat' => 54.618607, 'centre_lon' => -5.917511], |
|
| 134 | + 66125 => ['centre_lat' => 54.618607, 'centre_lon' => -5.917511], |
|
| 135 | 135 | # Belfast East |
| 136 | - 14329 => ['centre_lat' => 54.598324, 'centre_lon' => -5.892792 ], |
|
| 137 | - 66124 => ['centre_lat' => 54.598324, 'centre_lon' => -5.892792 ], |
|
| 136 | + 14329 => ['centre_lat' => 54.598324, 'centre_lon' => -5.892792], |
|
| 137 | + 66124 => ['centre_lat' => 54.598324, 'centre_lon' => -5.892792], |
|
| 138 | 138 | # Belfast South |
| 139 | - 14331 => ['centre_lat' => 54.582409, 'centre_lon' => -5.925064 ], |
|
| 140 | - 66126 => ['centre_lat' => 54.582409, 'centre_lon' => -5.925064 ], |
|
| 139 | + 14331 => ['centre_lat' => 54.582409, 'centre_lon' => -5.925064], |
|
| 140 | + 66126 => ['centre_lat' => 54.582409, 'centre_lon' => -5.925064], |
|
| 141 | 141 | # Belfast West |
| 142 | - 14315 => ['centre_lat' => 54.606277, 'centre_lon' => -5.956650 ], |
|
| 143 | - 66127 => ['centre_lat' => 54.606277, 'centre_lon' => -5.956650 ], |
|
| 142 | + 14315 => ['centre_lat' => 54.606277, 'centre_lon' => -5.956650], |
|
| 143 | + 66127 => ['centre_lat' => 54.606277, 'centre_lon' => -5.956650], |
|
| 144 | 144 | ]; |
| 145 | 145 | } |