@@ -2,7 +2,7 @@ |
||
| 2 | 2 | |
| 3 | 3 | <?php |
| 4 | 4 | |
| 5 | -include_once dirname(__FILE__) .'/../www/includes/easyparliament/init.php'; |
|
| 5 | +include_once dirname(__FILE__) . '/../www/includes/easyparliament/init.php'; |
|
| 6 | 6 | |
| 7 | 7 | $topics = new MySociety\TheyWorkForYou\Topics(); |
| 8 | 8 | |
@@ -2,8 +2,8 @@ discard block |
||
| 2 | 2 | # vim:sw=4:ts=4:et:nowrap |
| 3 | 3 | |
| 4 | 4 | include_once '../../../includes/easyparliament/init.php'; |
| 5 | -include_once INCLUDESPATH."easyparliament/member.php"; |
|
| 6 | -include_once INCLUDESPATH."easyparliament/glossary.php"; |
|
| 5 | +include_once INCLUDESPATH . "easyparliament/member.php"; |
|
| 6 | +include_once INCLUDESPATH . "easyparliament/glossary.php"; |
|
| 7 | 7 | |
| 8 | 8 | if (!DEVSITE) { |
| 9 | 9 | header('Cache-Control: max-age=86400'); # Once a day |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | |
| 50 | 50 | $DATA->set_page_metadata($this_page, 'title', $pagetitle); |
| 51 | 51 | |
| 52 | - $args = array ( |
|
| 52 | + $args = array( |
|
| 53 | 53 | 's' => $searchstring, |
| 54 | 54 | 'p' => $pagenum, |
| 55 | 55 | 'pop' => 1, |
@@ -5,7 +5,7 @@ discard block |
||
| 5 | 5 | $this_page = "commentreport"; |
| 6 | 6 | |
| 7 | 7 | include_once '../../includes/easyparliament/init.php'; |
| 8 | -include_once (INCLUDESPATH."easyparliament/commentreport.php"); |
|
| 8 | +include_once (INCLUDESPATH . "easyparliament/commentreport.php"); |
|
| 9 | 9 | |
| 10 | 10 | $PAGE->page_start(); |
| 11 | 11 | |
@@ -56,7 +56,7 @@ discard block |
||
| 56 | 56 | |
| 57 | 57 | $REPORT = new COMMENTREPORT; |
| 58 | 58 | |
| 59 | - $reportdata = array ( |
|
| 59 | + $reportdata = array( |
|
| 60 | 60 | 'body' => get_http_var('body'), |
| 61 | 61 | 'firstname' => get_http_var('firstname'), |
| 62 | 62 | 'lastname' => get_http_var('lastname'), |
@@ -84,7 +84,7 @@ discard block |
||
| 84 | 84 | |
| 85 | 85 | |
| 86 | 86 | } else { |
| 87 | - $PAGE->error_message ("Sorry, we were unable to add the report to the database."); |
|
| 87 | + $PAGE->error_message("Sorry, we were unable to add the report to the database."); |
|
| 88 | 88 | } |
| 89 | 89 | } |
| 90 | 90 | |
@@ -99,7 +99,7 @@ discard block |
||
| 99 | 99 | |
| 100 | 100 | |
| 101 | 101 | |
| 102 | -function display_form($COMMENT, $errors=array()) { |
|
| 102 | +function display_form($COMMENT, $errors = array()) { |
|
| 103 | 103 | global $this_page, $THEUSER, $PAGE; |
| 104 | 104 | |
| 105 | 105 | ?> |
@@ -38,7 +38,7 @@ discard block |
||
| 38 | 38 | "; |
| 39 | 39 | $subject = "Help make the laws we have to obey better! - TheyWorkForYou.com"; |
| 40 | 40 | |
| 41 | - print '<a href="mailto:?subject=' . rawurlencode($subject) . '&body='. rawurlencode($email) . '">Click here to open a new email and invite your friends, family and colleagues to get involved.</a>'; |
|
| 41 | + print '<a href="mailto:?subject=' . rawurlencode($subject) . '&body=' . rawurlencode($email) . '">Click here to open a new email and invite your friends, family and colleagues to get involved.</a>'; |
|
| 42 | 42 | } |
| 43 | 43 | |
| 44 | 44 | function freeourbills_share_page() { |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | print '<p><a href="/freeourbills/doshare"'; |
| 59 | 59 | #print 'onclick="share(this); return false;"'; |
| 60 | 60 | print ' title="' . |
| 61 | - _('E-mail this, post to del.icio.us, etc.'). '" class="share_link" rel="nofollow">'. |
|
| 62 | - _('Share this'). '</a></p>'; |
|
| 61 | + _('E-mail this, post to del.icio.us, etc.') . '" class="share_link" rel="nofollow">' . |
|
| 62 | + _('Share this') . '</a></p>'; |
|
| 63 | 63 | #freeourbills_share_form(); |
| 64 | 64 | } |
@@ -90,7 +90,7 @@ |
||
| 90 | 90 | |
| 91 | 91 | |
| 92 | 92 | |
| 93 | -function display_page ($errors=array()) { |
|
| 93 | +function display_page($errors = array()) { |
|
| 94 | 94 | global $this_page, $PAGE; |
| 95 | 95 | |
| 96 | 96 | if (isset($errors["sending"])) { |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | } |
| 69 | 69 | |
| 70 | 70 | $PAGE->stripe_end(array( |
| 71 | - array ( |
|
| 71 | + array( |
|
| 72 | 72 | 'type' => 'include', |
| 73 | 73 | 'content' => 'userconfirmed' |
| 74 | 74 | ) |
@@ -80,10 +80,10 @@ discard block |
||
| 80 | 80 | // The user's first visit to this page, and they have a registration token. |
| 81 | 81 | // So let's confirm them and hope they get logged in... |
| 82 | 82 | |
| 83 | - if (get_http_var('c') == 'email' ) { |
|
| 84 | - $success = $THEUSER->confirm_email( get_http_var('t') ); |
|
| 83 | + if (get_http_var('c') == 'email') { |
|
| 84 | + $success = $THEUSER->confirm_email(get_http_var('t')); |
|
| 85 | 85 | } else { |
| 86 | - $success = $THEUSER->confirm( get_http_var('t') ); |
|
| 86 | + $success = $THEUSER->confirm(get_http_var('t')); |
|
| 87 | 87 | } |
| 88 | 88 | |
| 89 | 89 | if (!$success) { |
@@ -102,7 +102,7 @@ discard block |
||
| 102 | 102 | |
| 103 | 103 | $this_page = 'userconfirmfailed'; |
| 104 | 104 | |
| 105 | - if ( !$PAGE->page_started() ) { |
|
| 105 | + if (!$PAGE->page_started()) { |
|
| 106 | 106 | $PAGE->page_start(); |
| 107 | 107 | |
| 108 | 108 | $PAGE->stripe_start(); |
@@ -32,7 +32,7 @@ |
||
| 32 | 32 | <?php |
| 33 | 33 | |
| 34 | 34 | $includes = array( |
| 35 | - array ( |
|
| 35 | + array( |
|
| 36 | 36 | 'type' => 'include', |
| 37 | 37 | 'content' => 'whatisthissite' |
| 38 | 38 | ), |
@@ -31,7 +31,7 @@ discard block |
||
| 31 | 31 | voteerror("Your browser must be able to accept cookies before you can register a vote."); |
| 32 | 32 | } else { |
| 33 | 33 | // Delete the test cookie. |
| 34 | - setcookie ('testcookie', ''); |
|
| 34 | + setcookie('testcookie', ''); |
|
| 35 | 35 | } |
| 36 | 36 | // On with the voting...! |
| 37 | 37 | |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | // We need to check the user can accept cookies, so... |
| 41 | 41 | |
| 42 | 42 | // Set a cookie |
| 43 | - setcookie ('testcookie', 'true'); |
|
| 43 | + setcookie('testcookie', 'true'); |
|
| 44 | 44 | |
| 45 | 45 | $ret = get_http_var('ret'); |
| 46 | 46 | $id = get_http_var('id'); |
@@ -67,7 +67,7 @@ discard block |
||
| 67 | 67 | |
| 68 | 68 | $PAGE->page_start(); |
| 69 | 69 | |
| 70 | - $message = array ( |
|
| 70 | + $message = array( |
|
| 71 | 71 | 'title' => 'Sorry', |
| 72 | 72 | 'text' => $text |
| 73 | 73 | ); |
@@ -158,7 +158,7 @@ discard block |
||
| 158 | 158 | $prev_epvotes[] = $epobject_id; |
| 159 | 159 | $new_cookie = implode('+', $prev_epvotes); |
| 160 | 160 | |
| 161 | - setcookie ("epvotes", $new_cookie, time()+60*60*24*365, "/", COOKIEDOMAIN); |
|
| 161 | + setcookie("epvotes", $new_cookie, time() + 60 * 60 * 24 * 365, "/", COOKIEDOMAIN); |
|
| 162 | 162 | |
| 163 | 163 | |
| 164 | 164 | } else { |
@@ -189,7 +189,7 @@ discard block |
||
| 189 | 189 | |
| 190 | 190 | $PAGE->page_start(); |
| 191 | 191 | |
| 192 | -$message = array ( |
|
| 192 | +$message = array( |
|
| 193 | 193 | 'title' => "Thanks for your vote", |
| 194 | 194 | 'text' => "<strong>Would you like to ask a question like this yourself?</strong> Use our <a href=\"http://www.whatdotheyknow.com\">Freedom of Information site</a>." |
| 195 | 195 | ); |
@@ -12,8 +12,8 @@ |
||
| 12 | 12 | |
| 13 | 13 | $ym = substr($date, 0, 7); |
| 14 | 14 | if ($ym != $last) { |
| 15 | - $url = WEBPATH . "news/archives/".str_replace("-", "/", $ym); |
|
| 16 | - print "<a href=\"$url\">".format_date($ym."-01", "F Y")."</a>"; |
|
| 15 | + $url = WEBPATH . "news/archives/" . str_replace("-", "/", $ym); |
|
| 16 | + print "<a href=\"$url\">" . format_date($ym . "-01", "F Y") . "</a>"; |
|
| 17 | 17 | print "<br>"; |
| 18 | 18 | $last = $ym; |
| 19 | 19 | } |