[aur-dev] [PATCH 4/7] actions_form.php: Hide empty form

Lukas Fleischer archlinux at cryptocrack.de
Tue Jul 17 16:47:12 EDT 2012


Do not show the actions form if it doesn't contain any elements. This
comes into effect if the virtual path feature is enabled and the current
user doesn't have TU/developer privileges.

Signed-off-by: Lukas Fleischer <archlinux at cryptocrack.de>
---
 web/template/actions_form.php | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/web/template/actions_form.php b/web/template/actions_form.php
index 4b3845d..bfc0611 100644
--- a/web/template/actions_form.php
+++ b/web/template/actions_form.php
@@ -1,3 +1,4 @@
+<?php if (!$USE_VIRTUAL_URLS || $atype == "Trusted User" || $atype == "Developer" ): ?>
 <div class="box">
 	<form action="<?php echo htmlspecialchars(get_pkg_uri($row['Name']), ENT_QUOTES); ?>" method="post">
 		<fieldset>
@@ -36,3 +37,4 @@
 		</fieldset>
 	</form>
 </div>
+<?php endif; ?>
-- 
1.7.11.2



More information about the aur-dev mailing list