@@ -2,14 +2,14 @@ discard block |
||
2 | 2 | // Some sketchy crap for displaying pending glossary additions |
3 | 3 | |
4 | 4 | include_once '../../includes/easyparliament/init.php'; |
5 | -include_once (INCLUDESPATH."easyparliament/editqueue.php"); |
|
6 | -include_once (INCLUDESPATH."easyparliament/glossary.php"); |
|
5 | +include_once (INCLUDESPATH . "easyparliament/editqueue.php"); |
|
6 | +include_once (INCLUDESPATH . "easyparliament/glossary.php"); |
|
7 | 7 | |
8 | 8 | $this_page = "admin_glossary_pending"; |
9 | 9 | |
10 | 10 | $EDITQUEUE = new GLOSSEDITQUEUE(); |
11 | 11 | |
12 | -$args = array ( |
|
12 | +$args = array( |
|
13 | 13 | 'sort' => "regexp_replace" |
14 | 14 | ); |
15 | 15 | $GLOSSARY = new GLOSSARY($args); |
@@ -24,19 +24,19 @@ discard block |
||
24 | 24 | if (get_http_var('approve')) { |
25 | 25 | $approve = get_http_var('approve'); |
26 | 26 | if (!is_array($approve)) { |
27 | - $approve = array ( $approve ); |
|
27 | + $approve = array($approve); |
|
28 | 28 | } |
29 | 29 | // Add all approved items |
30 | - $data = array ( |
|
30 | + $data = array( |
|
31 | 31 | 'approvals' => $approve, |
32 | 32 | 'epobject_type' => 2 |
33 | 33 | ); |
34 | 34 | $EDITQUEUE->approve($data); |
35 | 35 | } |
36 | 36 | elseif (get_http_var('decline')) { |
37 | - $decline = array (get_http_var('decline')); |
|
37 | + $decline = array(get_http_var('decline')); |
|
38 | 38 | // Dump all declined items |
39 | - $data = array ( |
|
39 | + $data = array( |
|
40 | 40 | 'declines' => $decline, |
41 | 41 | 'epobject_type' => 2 |
42 | 42 | ); |
@@ -55,8 +55,8 @@ discard block |
||
55 | 55 | |
56 | 56 | // Mock up a "current term" to send to the display function |
57 | 57 | if (get_http_var('previewterm')) { |
58 | - $body = get_http_var('definition'); |
|
59 | - $title = get_http_var('g'); |
|
58 | + $body = get_http_var('definition'); |
|
59 | + $title = get_http_var('g'); |
|
60 | 60 | } |
61 | 61 | else { |
62 | 62 | $body = $EDITQUEUE->pending[$glossary_id]['body']; |
@@ -116,7 +116,7 @@ discard block |
||
116 | 116 | |
117 | 117 | // add a modification to the database |
118 | 118 | if (get_http_var('submitterm') && get_http_var('modify')) { |
119 | - $data = array ( |
|
119 | + $data = array( |
|
120 | 120 | 'user_id' => get_http_var('userid'), |
121 | 121 | 'title' => get_http_var('g'), |
122 | 122 | 'body' => get_http_var('definition') |
@@ -1,7 +1,7 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | 3 | include_once '../../includes/easyparliament/init.php'; |
4 | -include_once (INCLUDESPATH."easyparliament/commentreportlist.php"); |
|
4 | +include_once (INCLUDESPATH . "easyparliament/commentreportlist.php"); |
|
5 | 5 | |
6 | 6 | $this_page = "admin_commentreports"; |
7 | 7 |
@@ -1,7 +1,7 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | 3 | include_once '../../includes/easyparliament/init.php'; |
4 | -include_once (INCLUDESPATH."easyparliament/commentreportlist.php"); |
|
4 | +include_once (INCLUDESPATH . "easyparliament/commentreportlist.php"); |
|
5 | 5 | |
6 | 6 | $this_page = "admin_trackbacks"; |
7 | 7 |
@@ -1,7 +1,7 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | 3 | include_once '../../includes/easyparliament/init.php'; |
4 | -include_once (INCLUDESPATH."easyparliament/commentreportlist.php"); |
|
4 | +include_once (INCLUDESPATH . "easyparliament/commentreportlist.php"); |
|
5 | 5 | |
6 | 6 | $this_page = "admin_comments"; |
7 | 7 |
@@ -70,7 +70,8 @@ |
||
70 | 70 | |
71 | 71 | if ($is_success) { |
72 | 72 | $out = "<h4>update successful</h4>"; |
73 | - } else { |
|
73 | + } |
|
74 | + else { |
|
74 | 75 | $out = "<h4>Failed to update Topics</h4>"; |
75 | 76 | } |
76 | 77 |
@@ -61,7 +61,7 @@ |
||
61 | 61 | global $banner; |
62 | 62 | $banner_text = get_http_var('banner'); |
63 | 63 | |
64 | - if ( $banner->set_text($banner_text) ) { |
|
64 | + if ($banner->set_text($banner_text)) { |
|
65 | 65 | $out = "<h4>update successful</h4>"; |
66 | 66 | $out .= "<p>Banner text is now:</p><p>$banner_text</p>"; |
67 | 67 | } else { |
@@ -64,7 +64,8 @@ |
||
64 | 64 | if ( $banner->set_text($banner_text) ) { |
65 | 65 | $out = "<h4>update successful</h4>"; |
66 | 66 | $out .= "<p>Banner text is now:</p><p>$banner_text</p>"; |
67 | - } else { |
|
67 | + } |
|
68 | + else { |
|
68 | 69 | $out = "<h4>Failed to update banner text</h4>"; |
69 | 70 | } |
70 | 71 |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | ) |
111 | 111 | ); |
112 | 112 | |
113 | - if ( $q->success() ) { |
|
113 | + if ($q->success()) { |
|
114 | 114 | $out = "<h4>update successful</h4>"; |
115 | 115 | } |
116 | 116 | |
@@ -125,9 +125,9 @@ discard block |
||
125 | 125 | |
126 | 126 | $rettext .= '<div id="subnav_websites">'; |
127 | 127 | foreach ($subnav as $label => $path) { |
128 | - $rettext .= '<a href="'. $path . '">'. $label .'</a>'; |
|
128 | + $rettext .= '<a href="' . $path . '">' . $label . '</a>'; |
|
129 | 129 | } |
130 | - $rettext .= '</div>'; |
|
130 | + $rettext .= '</div>'; |
|
131 | 131 | |
132 | 132 | return $rettext; |
133 | 133 | } |
@@ -22,7 +22,8 @@ |
||
22 | 22 | |
23 | 23 | if (get_http_var('editpolicy')) { |
24 | 24 | $out .= edit_policy_form(); |
25 | -} else { |
|
25 | +} |
|
26 | +else { |
|
26 | 27 | $out .= list_policies(); |
27 | 28 | } |
28 | 29 |
@@ -2,14 +2,14 @@ discard block |
||
2 | 2 | // Some sketchy crap for displaying pending glossary additions |
3 | 3 | |
4 | 4 | include_once '../../includes/easyparliament/init.php'; |
5 | -include_once (INCLUDESPATH."easyparliament/editqueue.php"); |
|
6 | -include_once (INCLUDESPATH."easyparliament/glossary.php"); |
|
5 | +include_once (INCLUDESPATH . "easyparliament/editqueue.php"); |
|
6 | +include_once (INCLUDESPATH . "easyparliament/glossary.php"); |
|
7 | 7 | |
8 | 8 | $this_page = "admin_glossary"; |
9 | 9 | |
10 | 10 | $EDITQUEUE = new GLOSSEDITQUEUE(); |
11 | 11 | |
12 | -$args = array ( |
|
12 | +$args = array( |
|
13 | 13 | 'sort' => "regexp_replace" |
14 | 14 | ); |
15 | 15 | |
@@ -22,19 +22,19 @@ discard block |
||
22 | 22 | if (get_http_var('approve')) { |
23 | 23 | $approve = get_http_var('approve'); |
24 | 24 | if (!is_array($approve)) { |
25 | - $approve = array ( $approve ); |
|
25 | + $approve = array($approve); |
|
26 | 26 | } |
27 | 27 | // Add all approved items |
28 | - $data = array ( |
|
28 | + $data = array( |
|
29 | 29 | 'approvals' => $approve, |
30 | 30 | 'epobject_type' => 2 |
31 | 31 | ); |
32 | 32 | $EDITQUEUE->approve($data); |
33 | 33 | } |
34 | 34 | elseif (get_http_var('decline')) { |
35 | - $decline = array (get_http_var('decline')); |
|
35 | + $decline = array(get_http_var('decline')); |
|
36 | 36 | // Dump all declined items |
37 | - $data = array ( |
|
37 | + $data = array( |
|
38 | 38 | 'declines' => $decline, |
39 | 39 | 'epobject_type' => 2 |
40 | 40 | ); |
@@ -100,11 +100,11 @@ |
||
100 | 100 | _api_getHansard_year('WMS', $y); |
101 | 101 | } |
102 | 102 | function api_getWMS_search($s) { |
103 | - _api_getHansard_search( array( |
|
103 | + _api_getHansard_search(array( |
|
104 | 104 | 's' => $s, |
105 | 105 | 'pid' => get_http_var('person'), |
106 | 106 | 'type' => 'wms', |
107 | - ) ); |
|
107 | + )); |
|
108 | 108 | } |
109 | 109 | function api_getWMS_person($pid) { |
110 | 110 | _api_getHansard_search(array( |