[Mon Sep 08 17:34:49 2008] [error] [client 209.204.68.120] PHP Parse
error: syntax error, unexpected '}' in /var/www/webui/policy-change.php
on line 14
I found the cause.
Line 117 of policy-change.php has a short tag opening:
116: <p class="pageheader">Policy Update Results</p>
117: <?
118: $updates = array();
Problem cleared up after setting short_tags to on in php.ini.
Thanks hopefully this helps someone else with the same problem.
The issue is alot more extensive though and affects most of the PHP
files. Thanks for pointing this out :)
Commit r310 should fix it in trunk and stable. Attached the patch (apply
from within the webui directory with -p0).
-N
Index: postfix-transports-change.php
===================================================================
--- postfix-transports-change.php (revision 307)
+++ postfix-transports-change.php (working copy)
@@ -131,7 +131,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Policy Group Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['postfix_transport_type'])) {
Index: policy-group-member-delete.php
===================================================================
--- policy-group-member-delete.php (revision 307)
+++ policy-group-member-delete.php (working copy)
@@ -70,7 +70,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Policy Group Member Delete Results</p>
-<?
+<?php
if (isset($_POST['policy_group_member_id'])) {
if ($_POST['confirm'] == "yes") {
Index: quotas-change.php
===================================================================
--- quotas-change.php (revision 307)
+++ quotas-change.php (working copy)
@@ -192,7 +192,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Access Control Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['quota_policyid'])) {
Index: policy-delete.php
===================================================================
--- policy-delete.php (revision 307)
+++ policy-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Policy Delete Results</p>
-<?
+<?php
if (isset($_POST['policy_id'])) {
Index: accesscontrol-delete.php
===================================================================
--- accesscontrol-delete.php (revision 307)
+++ accesscontrol-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Access Control Delete Results</p>
-<?
+<?php
if (isset($_POST['accesscontrol_id'])) {
if ($_POST['confirm'] == "yes") {
Index: checkhelo-delete.php
===================================================================
--- checkhelo-delete.php (revision 307)
+++ checkhelo-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">HELO/EHLO Check Delete Results</p>
-<?
+<?php
if (isset($_POST['checkhelo_id'])) {
if ($_POST['confirm'] == "yes") {
Index: postfix-distgroups-member-change.php
===================================================================
--- postfix-distgroups-member-change.php (revision 307)
+++ postfix-distgroups-member-change.php (working copy)
@@ -102,7 +102,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Distribution Group Member Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['postfix_group_member_goto'])) {
Index: checkhelo-blacklist-delete.php
===================================================================
--- checkhelo-blacklist-delete.php (revision 307)
+++ checkhelo-blacklist-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">HELO/EHLO Blacklist Delete Results</p>
-<?
+<?php
if (isset($_POST['blacklist_id'])) {
if ($_POST['confirm'] == "yes") {
Index: postfix-distgroups-delete.php
===================================================================
--- postfix-distgroups-delete.php (revision 307)
+++ postfix-distgroups-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Distribution Group Delete Results</p>
-<?
+<?php
if (isset($_POST['postfix_group_id'])) {
if ($_POST['confirm'] == "yes") {
Index: postfix-aliases-change.php
===================================================================
--- postfix-aliases-change.php (revision 307)
+++ postfix-aliases-change.php (working copy)
@@ -110,7 +110,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Policy Group Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['postfix_alias_goto'])) {
Index: quotas-limits-change.php
===================================================================
--- quotas-limits-change.php (revision 307)
+++ quotas-limits-change.php (working copy)
@@ -115,7 +115,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Policy Update Results</p>
-<?
+<?php
# Check a quota was selected
if (isset($_POST['quota_limit_id'])) {
Index: postfix-mailboxes-change.php
===================================================================
--- postfix-mailboxes-change.php (revision 307)
+++ postfix-mailboxes-change.php (working copy)
@@ -146,7 +146,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Mailbox Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['postfix_mailbox_name'])) {
Index: amavis-change.php
===================================================================
--- amavis-change.php (revision 307)
+++ amavis-change.php (working copy)
@@ -1019,7 +1019,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Amavis Rule Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['amavis_policyid'])) {
Index: postfix-transports-delete.php
===================================================================
--- postfix-transports-delete.php (revision 307)
+++ postfix-transports-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Postfix Transport Delete Results</p>
-<?
+<?php
if (isset($_POST['postfix_transport_id'])) {
if ($_POST['confirm'] == "yes") {
Index: checkspf-change.php
===================================================================
--- checkspf-change.php (revision 307)
+++ checkspf-change.php (working copy)
@@ -222,7 +222,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">SPF Check Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['checkspf_policyid'])) {
Index: policy-group-change.php
===================================================================
--- policy-group-change.php (revision 307)
+++ policy-group-change.php (working copy)
@@ -100,7 +100,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Policy Group Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['policy_group_name'])) {
Index: quotas-delete.php
===================================================================
--- quotas-delete.php (revision 307)
+++ quotas-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Quota Delete Results</p>
-<?
+<?php
if (isset($_POST['quota_id'])) {
if ($_POST['confirm'] == "yes") {
Index: checkhelo-whitelist-change.php
===================================================================
--- checkhelo-whitelist-change.php (revision 307)
+++ checkhelo-whitelist-change.php (working copy)
@@ -124,7 +124,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">HELO/EHLO Whitelisting Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['whitelist_type'])) {
Index: greylisting-change.php
===================================================================
--- greylisting-change.php (revision 307)
+++ greylisting-change.php (working copy)
@@ -411,7 +411,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Greylisting Update Results</p>
-<?
+<?php
$updates = array();
# Process all our options below
Index: policy-member-change.php
===================================================================
--- policy-member-change.php (revision 307)
+++ policy-member-change.php (working copy)
@@ -116,7 +116,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Policy Update Results</p>
-<?
+<?php
# Check a policy was selected
if (isset($_POST['policy_member_id'])) {
Index: greylisting-whitelist-change.php
===================================================================
--- greylisting-whitelist-change.php (revision 307)
+++ greylisting-whitelist-change.php (working copy)
@@ -125,7 +125,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Greylisting Whitelisting Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['whitelist_type'])) {
Index: postfix-distgroups-member-delete.php
===================================================================
--- postfix-distgroups-member-delete.php (revision 307)
+++ postfix-distgroups-member-delete.php (working copy)
@@ -70,7 +70,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Distribution Group Member Delete Results</p>
-<?
+<?php
if (isset($_POST['postfix_group_member_id'])) {
if ($_POST['confirm'] == "yes") {
Index: postfix-aliases-delete.php
===================================================================
--- postfix-aliases-delete.php (revision 307)
+++ postfix-aliases-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Postfix Alias Delete Results</p>
-<?
+<?php
if (isset($_POST['postfix_alias_id'])) {
if ($_POST['confirm'] == "yes") {
Index: quotas-limits-delete.php
===================================================================
--- quotas-limits-delete.php (revision 307)
+++ quotas-limits-delete.php (working copy)
@@ -71,7 +71,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Quota Limit Delete Results</p>
-<?
+<?php
if (isset($_POST['quota_limit_id'])) {
if ($_POST['confirm'] == "yes") {
Index: postfix-mailboxes-delete.php
===================================================================
--- postfix-mailboxes-delete.php (revision 307)
+++ postfix-mailboxes-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Mailbox Delete Results</p>
-<?
+<?php
if (isset($_POST['postfix_mailbox_id'])) {
if ($_POST['confirm'] == "yes") {
Index: amavis-delete.php
===================================================================
--- amavis-delete.php (revision 307)
+++ amavis-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Amavis Rule Delete Results</p>
-<?
+<?php
if (isset($_POST['amavis_id'])) {
if ($_POST['confirm'] == "yes") {
Index: policy-group-member-change.php
===================================================================
--- policy-group-member-change.php (revision 307)
+++ policy-group-member-change.php (working copy)
@@ -111,7 +111,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Policy Group Member Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['policy_group_member_member'])) {
Index: policy-change.php
===================================================================
--- policy-change.php (revision 307)
+++ policy-change.php (working copy)
@@ -114,7 +114,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Policy Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['policy_name'])) {
Index: accesscontrol-change.php
===================================================================
--- accesscontrol-change.php (revision 307)
+++ accesscontrol-change.php (working copy)
@@ -161,7 +161,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Access Control Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['accesscontrol_policyid'])) {
Index: checkspf-delete.php
===================================================================
--- checkspf-delete.php (revision 307)
+++ checkspf-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">SPF Check Delete Results</p>
-<?
+<?php
if (isset($_POST['checkspf_id'])) {
if ($_POST['confirm'] == "yes") {
Index: policy-group-delete.php
===================================================================
--- policy-group-delete.php (revision 307)
+++ policy-group-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Policy Group Delete Results</p>
-<?
+<?php
if (isset($_POST['policy_group_id'])) {
if ($_POST['confirm'] == "yes") {
Index: checkhelo-whitelist-delete.php
===================================================================
--- checkhelo-whitelist-delete.php (revision 307)
+++ checkhelo-whitelist-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">HELO/EHLO Whitelist Delete Results</p>
-<?
+<?php
if (isset($_POST['whitelist_id'])) {
if ($_POST['confirm'] == "yes") {
Index: greylisting-delete.php
===================================================================
--- greylisting-delete.php (revision 307)
+++ greylisting-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Greylisting Delete Results</p>
-<?
+<?php
if (isset($_POST['greylisting_id'])) {
if ($_POST['confirm'] == "yes") {
Index: policy-member-delete.php
===================================================================
--- policy-member-delete.php (revision 307)
+++ policy-member-delete.php (working copy)
@@ -71,7 +71,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Policy Member Delete Results</p>
-<?
+<?php
if (isset($_POST['policy_member_id'])) {
if ($_POST['confirm'] == "yes") {
Index: checkhelo-change.php
===================================================================
--- checkhelo-change.php (revision 307)
+++ checkhelo-change.php (working copy)
@@ -347,7 +347,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">HELO/EHLO Update Results</p>
-<?
+<?php
$updates = array();
# Process all our options below
Index: greylisting-whitelist-delete.php
===================================================================
--- greylisting-whitelist-delete.php (revision 307)
+++ greylisting-whitelist-delete.php (working copy)
@@ -69,7 +69,7 @@
} elseif ($_POST['frmaction'] == "delete2") {
?>
<p class="pageheader">Greylisting Whitelist Delete Results</p>
-<?
+<?php
if (isset($_POST['whitelist_id'])) {
if ($_POST['confirm'] == "yes") {
Index: checkhelo-blacklist-change.php
===================================================================
--- checkhelo-blacklist-change.php (revision 307)
+++ checkhelo-blacklist-change.php (working copy)
@@ -119,7 +119,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">HELO/EHLO Blacklisting Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['blacklist_helo'])) {
Index: postfix-distgroups-change.php
===================================================================
--- postfix-distgroups-change.php (revision 307)
+++ postfix-distgroups-change.php (working copy)
@@ -105,7 +105,7 @@
} elseif ($_POST['frmaction'] == "change2") {
?>
<p class="pageheader">Distribution Group Update Results</p>
-<?
+<?php
$updates = array();
if (!empty($_POST['postfix_group_comment'])) {
_______________________________________________
Users mailing list
[email protected]
http://lists.policyd.org/mailman/listinfo/users