@@ -11,7 +11,7 @@ discard block |
||
11 | 11 | |
12 | 12 | if (isset ($data['rows'])) { |
13 | 13 | $out = array(); |
14 | - for ($i=0; $i<count($data['rows']); $i++) { |
|
14 | + for ($i = 0; $i < count($data['rows']); $i++) { |
|
15 | 15 | $row = $data['rows'][$i]; |
16 | 16 | |
17 | 17 | if ($row['htype'] == '10' && isset($row['excerpt']) && strstr($row['excerpt'], "was asked—")) { |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | if ($row['htype'] == '10') { |
41 | 41 | $out[] = array('entry' => $entry, 'subs' => array()); |
42 | 42 | } else { |
43 | - $out[sizeof($out)-1]['subs'][] = $entry; |
|
43 | + $out[sizeof($out) - 1]['subs'][] = $entry; |
|
44 | 44 | } |
45 | 45 | |
46 | 46 | } |
@@ -38,10 +38,10 @@ |
||
38 | 38 | <p>There are <b><?=number_format($debate_speeches)?></b> debate speeches (<?=number_format($debate_items)?> items including headers). |
39 | 39 | <br>There are <b><?=number_format($wrans_questions)?></b> written questions (<?=number_format($wrans_items)?> items including headers and answers). |
40 | 40 | |
41 | -<!-- Debate items / in-session day: <?=round($debate_items/$uniquedates,0)?> |
|
42 | -Wrans items / in-session day: <?=round($wrans_items/$uniquedates,0)?> --> |
|
41 | +<!-- Debate items / in-session day: <?=round($debate_items / $uniquedates, 0)?> |
|
42 | +Wrans items / in-session day: <?=round($wrans_items / $uniquedates, 0)?> --> |
|
43 | 43 | |
44 | -<p>Per sitting day, MPs are producing <b><?=round($debate_speeches/$uniquedates,0)?></b> speeches, and <b><?=round($wrans_questions/$uniquedates,0)?></b> written answers. |
|
44 | +<p>Per sitting day, MPs are producing <b><?=round($debate_speeches / $uniquedates, 0)?></b> speeches, and <b><?=round($wrans_questions / $uniquedates, 0)?></b> written answers. |
|
45 | 45 | </p> |
46 | 46 | |
47 | 47 | <?php |
@@ -18,7 +18,7 @@ |
||
18 | 18 | $args = $people->getArgs(); |
19 | 19 | $people->setMetaData($args); |
20 | 20 | $data = $people->getData($args); |
21 | -if ( isset($args['f']) && $args['f'] == 'csv' ) { |
|
21 | +if (isset($args['f']) && $args['f'] == 'csv') { |
|
22 | 22 | $people->sendAsCSV($data); |
23 | 23 | } else { |
24 | 24 | MySociety\TheyWorkForYou\Renderer::output("people/index", $data); |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | } |
25 | 25 | |
26 | 26 | function api_getComments_start_date($start_date) { |
27 | - $args = array ( |
|
27 | + $args = array( |
|
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 = array ( |
|
36 | + $args = array( |
|
37 | 37 | 's' => $s, |
38 | 38 | 'p' => get_http_var('page'), |
39 | 39 | 'num' => get_http_var('num'), |
@@ -2,12 +2,12 @@ discard block |
||
2 | 2 | |
3 | 3 | $this_page = 'bill_index'; |
4 | 4 | include_once '../../../../includes/easyparliament/init.php'; |
5 | -$DATA->set_page_metadata($this_page, 'heading','Identity Cards Act 2006'); |
|
5 | +$DATA->set_page_metadata($this_page, 'heading', 'Identity Cards Act 2006'); |
|
6 | 6 | |
7 | 7 | $PAGE->page_start(); |
8 | 8 | $PAGE->stripe_start(); |
9 | 9 | |
10 | -$PAGE->block_start(array ('title'=>'House of Commons - Normal Run')); |
|
10 | +$PAGE->block_start(array('title'=>'House of Commons - Normal Run')); |
|
11 | 11 | ?> |
12 | 12 | <ul> <li>Back on 25th May 2005, a bill was introduced: the <a |
13 | 13 | href="http://www.publications.parliament.uk/pa/cm200506/cmbills/009/2006009.htm">Identity |
@@ -32,7 +32,7 @@ discard block |
||
32 | 32 | |
33 | 33 | <?php |
34 | 34 | $PAGE->block_end(); |
35 | -$PAGE->block_start(array ('title'=>'House of Lords - Normal Run')); |
|
35 | +$PAGE->block_start(array('title'=>'House of Lords - Normal Run')); |
|
36 | 36 | ?> |
37 | 37 | |
38 | 38 | <ul> |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | |
50 | 50 | <?php |
51 | 51 | $PAGE->block_end(); |
52 | -$PAGE->block_start(array ('title'=>'Ping Pong')); |
|
52 | +$PAGE->block_start(array('title'=>'Ping Pong')); |
|
53 | 53 | ?> |
54 | 54 | |
55 | 55 | <ul> |
@@ -94,7 +94,7 @@ discard block |
||
94 | 94 | $PAGE->block_end(); |
95 | 95 | |
96 | 96 | $includes = array( |
97 | - array ( |
|
97 | + array( |
|
98 | 98 | 'type' => 'include', |
99 | 99 | 'content' => 'bills_intro' |
100 | 100 | ), |
@@ -24,7 +24,7 @@ |
||
24 | 24 | |
25 | 25 | protected function getSearchSections() { |
26 | 26 | return array( |
27 | - array( 'section' => 'sp' ) |
|
27 | + array('section' => 'sp') |
|
28 | 28 | ); |
29 | 29 | } |
30 | 30 | } |
@@ -12,13 +12,13 @@ discard block |
||
12 | 12 | |
13 | 13 | protected function display_front() { |
14 | 14 | global $DATA, $this_page; |
15 | - if ( get_http_var('type') == 'wrans') { |
|
15 | + if (get_http_var('type') == 'wrans') { |
|
16 | 16 | return parent::display_front(); |
17 | 17 | } |
18 | 18 | |
19 | 19 | $data = array(); |
20 | 20 | |
21 | - $args = array( 'months' => 1 ); |
|
21 | + $args = array('months' => 1); |
|
22 | 22 | $WRANSLIST = new \WRANSLIST; |
23 | 23 | |
24 | 24 | $wrans = array(); |
@@ -50,10 +50,10 @@ discard block |
||
50 | 50 | |
51 | 51 | protected function getSearchSections() { |
52 | 52 | $sections = array( |
53 | - array( 'section' => 'wrans', 'title' => 'Written Answers' ), |
|
53 | + array('section' => 'wrans', 'title' => 'Written Answers'), |
|
54 | 54 | ); |
55 | - if ( get_http_var('type') == '') { |
|
56 | - $sections[] = array( 'section' => 'wms', 'title' => 'Written Ministerial Statements' ); |
|
55 | + if (get_http_var('type') == '') { |
|
56 | + $sections[] = array('section' => 'wms', 'title' => 'Written Ministerial Statements'); |
|
57 | 57 | } |
58 | 58 | return $sections; |
59 | 59 | } |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | # speech bar the first (assuming that's the question) |
63 | 63 | private $votelinks_so_far = 0; |
64 | 64 | |
65 | - protected function generate_votes ($votes, $id, $gid) { |
|
65 | + protected function generate_votes($votes, $id, $gid) { |
|
66 | 66 | /* |
67 | 67 | Returns HTML for the 'Does this answer the question?' links (wrans) in the sidebar. |
68 | 68 | $votes = => array ( |
@@ -31,7 +31,7 @@ |
||
31 | 31 | </li> |
32 | 32 | |
33 | 33 | <?php |
34 | -$user_agent = ( isset( $_SERVER['HTTP_USER_AGENT'] ) ) ? strtolower( $_SERVER['HTTP_USER_AGENT'] ) : ''; |
|
34 | +$user_agent = (isset($_SERVER['HTTP_USER_AGENT'])) ? strtolower($_SERVER['HTTP_USER_AGENT']) : ''; |
|
35 | 35 | if (stristr($user_agent, 'Firefox/')) { |
36 | 36 | ?> |
37 | 37 | <li>You can also add TheyWorkForYou to <a href="http://mycroft.mozdev.org/download.html?name=theyworkforyou">Firefox's search box</a>.</li> |
@@ -19,14 +19,14 @@ discard block |
||
19 | 19 | if (get_http_var("submitted") == "true") { |
20 | 20 | // Form has been submitted, so check input. |
21 | 21 | |
22 | - $email = get_http_var("email"); |
|
22 | + $email = get_http_var("email"); |
|
23 | 23 | $password = get_http_var("password"); |
24 | 24 | $remember = get_http_var("remember"); |
25 | 25 | |
26 | 26 | // The user may have tried to do something that requires being logged in. |
27 | 27 | // In which case we should arrive here with that page's URL in 'ret'. |
28 | 28 | // We can then send the user there after log in. |
29 | - $returnurl = get_http_var("ret"); |
|
29 | + $returnurl = get_http_var("ret"); |
|
30 | 30 | |
31 | 31 | $errors = array(); |
32 | 32 | |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | if ($remember == "true") { |
54 | 54 | $expire = "never"; |
55 | 55 | } else { |
56 | - $expire ="session"; |
|
56 | + $expire = "session"; |
|
57 | 57 | } |
58 | 58 | |
59 | 59 | // $returnurl is the url of where we'll send the user after login. |
@@ -96,7 +96,7 @@ discard block |
||
96 | 96 | } |
97 | 97 | |
98 | 98 | |
99 | -function display_page( $errors=array() ) { |
|
99 | +function display_page($errors = array()) { |
|
100 | 100 | global $PAGE, $this_page, $THEUSER; |
101 | 101 | |
102 | 102 | $PAGE->page_start(); |
@@ -127,7 +127,7 @@ discard block |
||
127 | 127 | <?php |
128 | 128 | |
129 | 129 | $PAGE->stripe_end(array( |
130 | - array ( |
|
130 | + array( |
|
131 | 131 | 'type' => 'include', |
132 | 132 | 'content' => 'userlogin' |
133 | 133 | ) |