[Fusionforge-commits] FusionForge branch master updated. 6.0.4-831-gcdd89f7

Franck Villaume nerville at libremir.placard.fr.eu.org
Sat Sep 3 14:34:27 CEST 2016


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, master has been updated
       via  cdd89f7d1fa43fd19bb38939cc3b59564002809b (commit)
      from  d10c0bf8a002e471b1f491d21b2e9081e252fb30 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=cdd89f7d1fa43fd19bb38939cc3b59564002809b

commit cdd89f7d1fa43fd19bb38939cc3b59564002809b
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Sat Sep 3 14:34:07 2016 +0200

    use HTML helpers

diff --git a/src/common/include/Navigation.class.php b/src/common/include/Navigation.class.php
index 9872c9c..4c7659d 100644
--- a/src/common/include/Navigation.class.php
+++ b/src/common/include/Navigation.class.php
@@ -3,7 +3,7 @@
  * FusionForge navigation
  *
  * Copyright 2009 - 2010, Olaf Lenz
- * Copyright 2011-2012, Franck Villaume - TrivialDev
+ * Copyright 2011-2012,2016, Franck Villaume - TrivialDev
  * Copyright 2014, Stéphane-Eymeric Bredthauer
  *
  * This file is part of FusionForge. FusionForge is free software;
@@ -122,7 +122,7 @@ class Navigation extends FFError {
 	 * Get the searchBox HTML code.
 	 */
 	function getSearchBox() {
-		global $words, $forum_id, $group_id, $group_project_id, $atid, $exact, $type_of_search;
+		global $words, $forum_id, $group_id, $group_project_id, $atid, $exact, $type_of_search, $HTML;
 
 		$res = "";
 		if (get_magic_quotes_gpc()) {
@@ -138,7 +138,7 @@ class Navigation extends FFError {
 			$exact = 1;
 		}
 
-		$res .= html_ao('form', array('id' => 'searchBox', 'action' => util_make_uri('/search/'), 'method' => 'get'));
+		$res .= $HTML->openForm(array('id' => 'searchBox', 'action' => '/search/', 'method' => 'get'));
 		$res .= html_ao('div', array());
 		$parameters = array(
 			SEARCH__PARAMETER_GROUP_ID => $group_id,
@@ -172,7 +172,8 @@ class Navigation extends FFError {
 		if (isset($group_id) && $group_id) {
 			$res .= util_make_link('/search/advanced_search.php?group_id='.$group_id, _('Advanced search'));
 		}
-		$res .= html_ac(html_ap() - 2);
+		$res .= html_ac(html_ap() - 1);
+		$res .= $HTML->closeForm();
 
 		return $res;
 	}
diff --git a/src/www/admin/approve-pending.php b/src/www/admin/approve-pending.php
index 997bc40..40b5bb0 100644
--- a/src/www/admin/approve-pending.php
+++ b/src/www/admin/approve-pending.php
@@ -5,6 +5,7 @@
  * Copyright 1999-2001 (c) VA Linux Systems
  * Copyright 2010 (c) Franck Villaume - Capgemini
  * Copyright (C) 2011 Alain Peyrat - Alcatel-Lucent
+ * Copyright 2016, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge. FusionForge is free software;
  * you can redistribute it and/or modify it under the terms of the
@@ -53,9 +54,9 @@ function activate_group($group_id) {
 	}
 
 	if ($group->approve(session_get_user())) {
-		$feedback .= sprintf(_('Approving Project: %s'), $group->getUnixName()).'<br />';
+		$feedback .= _('Approving Project')._(': ').$group->getUnixName().'<br />';
 	} else {
-		$error_msg .= sprintf(_('Error when approving Project: %s'), $group->getUnixName()).'<br />';
+		$error_msg .= _('Error when approving Project')._(': ').$group->getUnixName().'<br />';
 		$error_msg .= $group->getErrorMessage();
 		return false;
 	}
@@ -86,7 +87,7 @@ if ($action == 'activate') {
 	}
 
 	if (!$group->setStatus(session_get_user(), 'D')) {
-		exit_error(_('Error during group rejection: ').$this->getErrorMessage(), 'admin');
+		exit_error(_('Error during group rejection')._(': ').$this->getErrorMessage(), 'admin');
 	}
 
 	$group->addHistory('rejected', 'x');
@@ -121,16 +122,16 @@ if ($rows < 1) {
 }
 
 if ($rows > $LIMIT) {
-	print '<p>'. _('Pending projects:'). " $LIMIT+ ($LIMIT shown)</p>";
+	print '<p>'. _('Pending projects')._(':'). " $LIMIT+ ($LIMIT shown)</p>";
 } else {
-	print '<p>'. _('Pending projects:'). " $rows</p>";
+	print '<p>'. _('Pending projects')._(':'). " $rows</p>";
 }
 
 while ($row_grp = db_fetch_array($res_grp)) {
 
 	?>
 	<hr />
-	<h2><?php echo _('Pending') . ': <i>'. $row_grp['group_name'] . '</i>'; ?></h2>
+	<h2><?php echo _('Pending')._(': ').'<i>'. $row_grp['group_name'] . '</i>'; ?></h2>
 
 	<h3><?php  echo _('Pre-approval modifications :'); ?></h3>
 
@@ -140,19 +141,21 @@ while ($row_grp = db_fetch_array($res_grp)) {
 	echo _(' or ');
 	echo util_make_link('/admin/userlist.php?group_id='.$row_grp['group_id'],_('View/Edit Project Members')); ?></p>
 
-	<h3><?php echo _('Decision :'); ?></h3>
+	<h3><?php echo _('Decision')._(':'); ?></h3>
 	<table><tr class="bottom"><td>
-
-	<form name="approve.<?php echo $row_grp['unix_group_name'] ?>" action="<?php echo util_make_uri('/admin/approve-pending.php'); ?>" method="post">
+	<?php
+	echo $HTML->openForm(array('name' => 'approve'.$row_grp['unix_group_name'], 'action' => '/admin/approve-pending.php', 'method' => 'post'));
+	?>
 	<input type="hidden" name="action" value="activate" />
 	<input type="hidden" name="list_of_groups" value="<?php print $row_grp['group_id']; ?>" />
 	<input type="submit" name="submit" value="<?php echo _('Approve'); ?>" />
-	</form>
+	<?php echo $HTML->closeForm(); ?>
 
 	</td><td><?php echo _(' or '); ?>
 	</td><td>
-
-	<form action="<?php echo util_make_uri('/admin/approve-pending.php'); ?>" method="post">
+	<?php
+	echo $HTML->openForm(array('action' => '/admin/approve-pending.php', 'method' => 'post'));
+	?>
 	<input type="hidden" name="action" value="delete" />
 	<input type="hidden" name="group_id" value="<?php print $row_grp['group_id']; ?>" />
 	<?php echo _('Rejection canned responses'); ?><br />
@@ -165,11 +168,11 @@ while ($row_grp = db_fetch_array($res_grp)) {
 	<input type="checkbox" name="add_to_can" value="<?php echo _('Yes'); ?>" /><?php echo _('Add this custom response to canned responses') ;?>
 	<br />
 	<input type="submit" name="submit" value="<?php echo _('Reject'); ?>" />
-	</form>
+	<?php echo $HTML->closeForm(); ?>
 	</td></tr>
 	</table>
 
-	<h3><?php  echo _('Project details :'); ?></h3>
+	<h3><?php  echo _('Project details')._(':'); ?></h3>
 
 	<table>
 	<tr class="top"><td>
@@ -177,11 +180,11 @@ while ($row_grp = db_fetch_array($res_grp)) {
 
 		if (forge_get_config('use_shell')) {
 	?>
-	<strong><?php echo _('Home Box:')."</strong></td><td>"; print $row_grp['unix_box']; ?></tr>
+	<strong><?php echo _('Home Box')._(': ')."</strong></td><td>"; print $row_grp['unix_box']; ?></tr>
 	<?php
 		} //end of sys_use_shell
 	?>
-	<tr><td><strong><?php echo _('HTTP Domain:')."</strong></td><td>"; print $row_grp['http_domain']; ?></td>
+	<tr><td><strong><?php echo _('HTTP Domain')._(': ')."</strong></td><td>"; print $row_grp['http_domain']; ?></td>
 
 	</tr>
 
@@ -197,11 +200,11 @@ while ($row_grp = db_fetch_array($res_grp)) {
 	print "<tr><td>" ._('Purpose of submission:'). "</td><td><blockquote>".$row_grp['register_purpose']."</blockquote></td></tr>";
 
 	if ($row_grp['license']=="other") {
-		print "<tr><td>" ._('License Other:'). "</td><td><blockquote>".$row_grp['license_other']."</blockquote></td></tr>";
+		print "<tr><td>" ._('License Other')._(': '). "</td><td><blockquote>".$row_grp['license_other']."</blockquote></td></tr>";
 	}
 
 	if (isset($row_grp['status_comment'])) {
-		print "<tr><td>" ._('Pending reason:'). "</td><td><span class=\"important\">".$row_grp['status_comment']."</span></td></tr>";
+		print "<tr><td>" ._('Pending reason')._(': '). "</td><td><span class=\"important\">".$row_grp['status_comment']."</span></td></tr>";
 	}
 
 	$submitter = NULL ;
@@ -225,16 +228,14 @@ while ($row_grp = db_fetch_array($res_grp)) {
 $arr = util_result_column_to_array($res_grp, 0);
 $group_list = implode($arr, ',');
 
+echo $HTML->openForm(array('action' => '/admin/approve-pending.php', 'method' => 'post'));
 echo '
-	<form action="'.util_make_uri('/admin/approve-pending.php').'" method="post">
 	<p class="align-center">
 	<input type="hidden" name="action" value="activate" />
 	<input type="hidden" name="list_of_groups" value="'.$group_list.'" />
 	<input type="submit" name="submit" value="'._('Approve All On This Page').'" />
-	</p>
-	</form>
-	';
-
+	</p>';
+echo $HTML->closeForm();
 site_admin_footer();
 
 // Local Variables:
diff --git a/src/www/admin/trove/trove_cat_add.php b/src/www/admin/trove/trove_cat_add.php
index 346bd53..a840027 100644
--- a/src/www/admin/trove/trove_cat_add.php
+++ b/src/www/admin/trove/trove_cat_add.php
@@ -4,6 +4,7 @@
  *
  * Copyright 1999-2001 (c) VA Linux Systems
  * Copyright (C) 2010 Alain Peyrat - Alcatel-Lucent
+ * Copyright 2016, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge. FusionForge is free software;
  * you can redistribute it and/or modify it under the terms of the
@@ -26,6 +27,8 @@ require_once $gfcommon.'include/pre.php';
 require_once $gfwww.'include/trove.php';
 require_once $gfwww.'admin/admin_utils.php';
 
+global $HTML, $error_msg;
+
 session_require_global_perm ('forge_admin');
 
 // ########################################################
@@ -70,15 +73,13 @@ if (getStringFromRequest('submit')) {
 }
 
 site_admin_header(array('title'=>_('Add New Trove Category')));
+echo $HTML->openForm(array('action' => '/admin/trove/trove_cat_add.php', 'method' => 'post'));
 ?>
-
-<form action="<?php echo util_make_uri('/admin/trove/trove_cat_add.php'); ?>" method="post">
 <input type="hidden" name="form_key" value="<?php echo form_generate_key(); ?>" />
 <p><?php echo _('Parent Category').utils_requiredField()._(':'); ?>
 <br /><select name="form_parent">
 
 <?php
-
 // generate list of possible parents
 // <paul at zootweb.com> 4/2/2003 - If we were given a parent trove use it
 // in the "Parent Category" box otherwise give them the complete list.
@@ -103,7 +104,6 @@ if ($parent_trove_cat_id != -1) {
 		print ('<option value="'.$row_cat["trove_cat_id"].'">'.$row_cat["fullname"]."</option>");
 	}
 }
-
 ?>
 
 </select></p>
@@ -114,8 +114,6 @@ if ($parent_trove_cat_id != -1) {
 <p><?php echo _('New category description (maximum length is 255 chars)')._(':'); ?>
 <br /><input type="text" size="80" name="form_description" /></p>
 <p><input type="submit" name="submit" value="<?php echo _('Add'); ?>" /></p>
-</form>
-
 <?php
-
+echo $HTML->closeForm();
 site_admin_footer();
diff --git a/src/www/admin/trove/trove_cat_edit.php b/src/www/admin/trove/trove_cat_edit.php
index dcc0f3c..b98a445 100644
--- a/src/www/admin/trove/trove_cat_edit.php
+++ b/src/www/admin/trove/trove_cat_edit.php
@@ -7,6 +7,7 @@
  *
  * Copyright 1999-2001 (c) VA Linux Systems
  * Copyright (C) 2010 Alain Peyrat - Alcatel-Lucent
+ * Copyright 2016, Franck Villaume - TrivialDev
  *
  * This file is part of FusionForge. FusionForge is free software;
  * you can redistribute it and/or modify it under the terms of the
@@ -108,10 +109,9 @@ if (db_numrows($res_cat)<1) {
 $row_cat = db_fetch_array($res_cat);
 
 site_admin_header(array('title'=>_('Edit Trove Category')));
+echo $HTML->openForm(array('action' => '/admin/trove/trove_cat_edit.php', 'method' => 'post'));
 ?>
 
-<form action="<?php echo util_make_uri('/admin/trove/trove_cat_edit.php'); ?>" method="post">
-
 <p><?php echo _('Parent Category')._(':'); ?>
 <br /><select name="form_parent">
 
@@ -148,10 +148,8 @@ while ($row_parent = db_fetch_array($res_parent)) {
 <br /><input type="text" name="form_description" size="80" value="<?php print $row_cat["description"]; ?>" /></p>
 
 <br /><input type="submit" name="submit" value="<?php echo _('Update'); ?>" /><input type="submit" name="delete" value="<?php echo _('Delete'); ?>" />
-</form>
-
 <?php
-
+echo $HTML->closeForm();
 site_admin_footer();
 
 // Local Variables:
diff --git a/src/www/include/vote_function.php b/src/www/include/vote_function.php
index b882406..a644bfa 100644
--- a/src/www/include/vote_function.php
+++ b/src/www/include/vote_function.php
@@ -4,7 +4,7 @@
  *
  * Copyright 1999-2001 (c) VA Linux Systems
  * Copyright 2010, FusionForge Team
- * Copyright 2013, Franck Villaume - TrivialDev
+ * Copyright 2013,2016, Franck Villaume - TrivialDev
  * http://fusionforge.org
  *
  * This file is part of FusionForge. FusionForge is free software;
@@ -96,6 +96,7 @@ function vote_get_rating ($id, $flag) {
  * @param		string	$flag		The rating type
  */
 function vote_show_release_radios ($vote_on_id, $flag) {
+	global $HTML;
 	/*
 		$flag
 		project - 1
@@ -111,9 +112,8 @@ function vote_show_release_radios ($vote_on_id, $flag) {
 	}
 	$rating=((16*vote_get_rating ($vote_on_id,$flag))-15);
 
+	echo $HTML->openForm(array('action' => '/survey/rating_resp.php', 'method' => 'post'));
 	?>
-
-	<form action="/survey/rating_resp.php" method="post">
 	<input type="radio" name="vote_on_id" value="<?php echo $vote_on_id; ?>" />
 	<input type="radio" name="redirect_to" value="<?php echo urlencode(getStringFromServer('REQUEST_URI')); ?>" />
 	<input type="radio" name="flag" value="<?php echo $flag; ?>" />
@@ -133,10 +133,8 @@ function vote_show_release_radios ($vote_on_id, $flag) {
 	<br />
 	<input type="submit" name="submit" value="Rate" />
 	</div>
-	</form>
-
 	<?php
-
+	echo $HTML->closeForm();
 }
 
 /**
@@ -146,6 +144,7 @@ function vote_show_release_radios ($vote_on_id, $flag) {
  * @param		int		$survey_id	The survey ID
  */
 function show_survey ($group_id, $survey_id) {
+	global $HTML;
 /*
 	Select this survey from the database
 */
@@ -155,10 +154,9 @@ function show_survey ($group_id, $survey_id) {
 					  $group_id));
 
 if (db_numrows($result) > 0) {
-	echo '
-		<h3>'.db_result($result, 0, 'survey_title').'</h3>
-		<form action="'.util_make_uri('/survey/survey_resp.php').'" method="post">
-		<input type="hidden" name="group_id" value="'.$group_id.'" />
+	echo '<h3>'.db_result($result, 0, 'survey_title').'</h3>';
+	echo $HTML->openForm(array('action' => '/survey/survey_resp.php', 'method' => 'post'));
+	echo ' <input type="hidden" name="group_id" value="'.$group_id.'" />
 		<input type="hidden" name="survey_id" value="'.$survey_id.'" />';
 
 	/*
@@ -288,8 +286,8 @@ if (db_numrows($result) > 0) {
 	<?php echo util_make_link('/survey/privacy.php?group_id='.$group_id,_('Survey Privacy')) ?>
 	<?php
 	echo "</td></tr>\n";
-	echo "</form>\n";
 	echo "</table>\n";
+	echo $HTML->closeForm();
 
 } else {
 	echo "<strong>"._('Survey not found.')."</strong>";
@@ -407,10 +405,9 @@ function vote_show_user_rate_box ($user_id, $by_id=0) {
 		}
 	}
 
-	global $USER_RATING_VALUES,$USER_RATING_QUESTIONS;
-	echo '
-	<form action="/developer/rate.php" method="post">
-	<input type="hidden" name="rated_user" value="'.$user_id.'" />
+	global $USER_RATING_VALUES,$USER_RATING_QUESTIONS, $HTML;
+	echo $HTML->openForm(array('action' => '/developer/rate.php', 'method' => 'post'));
+	echo '<input type="hidden" name="rated_user" value="'.$user_id.'" />
 	<table>';
 	for ($i=1; $i<=count($USER_RATING_QUESTIONS); $i++) {
 		$popup="USER_RATING_POPUP$i";
@@ -429,8 +426,8 @@ function vote_show_user_rate_box ($user_id, $by_id=0) {
 		<tr><td colspan="2">
 			<input type="submit" name="submit" value="Rate User" />
 		</td></tr>
-		</table>
-	</form>';
+		</table>';
+	echo $HTML->closeForm();
 }
 
 /**
diff --git a/src/www/pm/add_task.php b/src/www/pm/add_task.php
index 867cbf7..9b224f3 100644
--- a/src/www/pm/add_task.php
+++ b/src/www/pm/add_task.php
@@ -4,7 +4,7 @@
  *
  * Copyright 1999-2000, Tim Perdue/Sourceforge
  * Copyright 2002, Tim Perdue/GForge, LLC
- * Copyright 2014, Franck Villaume - TrivialDev
+ * Copyright 2014,2016, Franck Villaume - TrivialDev
  * http://fusionforge.org
  *
  * This file is part of FusionForge. FusionForge is free software;
@@ -40,9 +40,8 @@ $params['width'] = "100%";
 $params['content'] = '<textarea required="required" name="details" rows="5" cols="80"></textarea>';
 plugin_hook_by_reference("text_editor", $params);
 
+echo $HTML->openForm(array('id' => 'addtaskform', 'action' => '/pm/task.php?group_id='.$group_id.'&group_project_id='.$group_project_id, 'method' => 'post'));
 ?>
-
-<form id="addtaskform" action="<?php echo util_make_uri('/pm/task.php?group_id='.$group_id.'&group_project_id='.$group_project_id) ?>" method="post">
 <input type="hidden" name="func" value="postaddtask" />
 <input type="hidden" name="add_artifact_id[]" value="<?php echo $related_artifact_id; ?>" />
 
@@ -110,10 +109,7 @@ $cells[] = array('<input type="submit" value="'._('Submit').'" name="submit" />'
 		'colspan' => 2);
 echo $HTML->multiTableRow(array(), $cells);
 echo $HTML->listTableBottom();
-?>
-</form>
-<?php
-
+echo $HTML->closeForm();
 pm_footer();
 
 // Local Variables:
diff --git a/src/www/pm/admin/index.php b/src/www/pm/admin/index.php
index e500116..0a98cb7 100644
--- a/src/www/pm/admin/index.php
+++ b/src/www/pm/admin/index.php
@@ -6,7 +6,7 @@
  * Copyright 2002 GForge, LLC, Tim Perdue
  * Copyright 2010, FusionForge Team
  * Copyright (C) 2011-2012 Alain Peyrat - Alcatel-Lucent
- * Copyright 2013-2014, Franck Villaume - TrivialDev
+ * Copyright 2013-2014,2016, Franck Villaume - TrivialDev
  * http://fusionforge.org
  *
  * This file is part of FusionForge. FusionForge is free software;
@@ -200,9 +200,8 @@ if ($add_cat && $group_project_id) {
 	} else {
 		echo $HTML->information(_('No categories defined'));
 	}
-
+	echo $HTML->openForm(array('action' => '/pm/admin/?group_id='.$group_id, 'method' => 'post'));
 	?>
-	<form action="<?php echo util_make_uri('/pm/admin/?group_id='.$group_id); ?>" method="post">
 	<p>
 	<input type="hidden" name="add_cat" value="y" />
 	<input type="hidden" name="group_project_id" value="<?php echo $pg->getID(); ?>" />
@@ -213,9 +212,8 @@ if ($add_cat && $group_project_id) {
 	</p>
 	<p class="important"><?php echo _('Once you add a category, it cannot be deleted') ?></p>
 	<p><input type="submit" name="post_changes" value="<?php echo _('Submit') ?>" /></p>
-	</form>
 	<?php
-
+	echo $HTML->closeForm();
 	pm_footer();
 
 } elseif ($update_cat && $group_project_id && $id) {
@@ -246,8 +244,8 @@ if ($add_cat && $group_project_id) {
 		exit_error($ac->getErrorMessage(),'pm');
 	} else {
 		echo $HTML->information(_('It is not recommended that you change the category name because other things are dependent upon it. When you change the category name, all related items will be changed to the new name.'));
+		echo $HTML->openForm(array('action' => '/pm/admin/?group_id='.$group_id, 'method' => 'post'));
 		?>
-		<form action="<?php echo util_make_uri('/pm/admin/?group_id='.$group_id); ?>" method="post">
 		<p>
 		<input type="hidden" name="update_cat" value="y" />
 		<input type="hidden" name="id" value="<?php echo $ac->getID(); ?>" />
@@ -258,8 +256,8 @@ if ($add_cat && $group_project_id) {
 		<input id="name" required="required" type="text" name="name" value="<?php echo $ac->getName(); ?>" />
 		</p>
 		<p><input type="submit" name="post_changes" value="<?php echo _('Submit') ?>" /></p>
-		</form>
 		<?php
+		echo $HTML->closeForm();
 	}
 
 	pm_footer();
@@ -274,8 +272,9 @@ if ($add_cat && $group_project_id) {
 
 	?>
 	<p><?php echo _('Add a new subproject to the Tasks. <strong>This is different than adding a task to a subproject.</strong>') ?></p>
-
-	<form action="<?php echo util_make_uri('/pm/admin/?group_id='.$group_id); ?>" method="post">
+	<?php
+	echo $HTML->openForm(array('action' => '/pm/admin/?group_id='.$group_id, 'method' => 'post'));
+	?>
 	<p>
 	<input type="hidden" name="addproject" value="y" />
 	<input type="hidden" name="post_changes" value="y" />
@@ -289,8 +288,8 @@ if ($add_cat && $group_project_id) {
 	<strong><?php echo _('Send All Updates To')._(':'); ?></strong><br />
 	<input type="email" name="send_all_posts_to" value="" size="40" maxlength="80" /><p />
 	<input type="submit" name="submit" value="<?php echo _('Submit') ?>" />
-	</form>
 	<?php
+	echo $HTML->closeForm();
 	pm_footer();
 
 } elseif (getStringFromRequest('update_pg') && $group_project_id) {
@@ -307,8 +306,9 @@ if ($add_cat && $group_project_id) {
 
 	?>
 	<p><?php echo _('You can modify an existing subproject using this form. Please note that private subprojects can still be viewed by members of your project, but not the general public.') ?></p>
-
-	<form action="<?php echo util_make_uri('/pm/admin/?group_id='.$group_id);; ?>" method="post">
+	<?php
+	echo $HTML->openForm(array('action' => '/pm/admin/?group_id='.$group_id, 'method' => 'post'));
+	?>
 	<input type="hidden" name="post_changes" value="y" />
 	<input type="hidden" name="update_pg" value="y" />
 	<input type="hidden" name="group_project_id" value="<?php echo $pg->getID(); ?>" />
@@ -349,8 +349,8 @@ if ($add_cat && $group_project_id) {
 		</td>
 	</tr>
 	</table>
-	</form>
 	<?php
+	echo $HTML->closeForm();
 	echo '<p>'.util_make_link('/pm/admin/?group_id='.$group_id.'&add_cat=1&group_project_id='.$group_project_id,_('Category Administration')).'</p>';
 	pm_footer();
 
@@ -367,9 +367,8 @@ if ($add_cat && $group_project_id) {
 
 	pm_header(array('title'=>_('Permanently delete this subproject and all its data'),
 					'modal'=>1));
-
+	echo $HTML->openForm(array('action' => '/pm/admin/?group_id='.$group_id.'&group_project_id='.$group_project_id, 'method' => 'post'));
 	?>
-	<form action="<?php echo util_make_uri('/pm/admin/?group_id='.$group_id.'&group_project_id='.$group_project_id); ?>" method="post">
 	<p>
 	<input type="hidden" name="post_changes" value="y" />
 	<input type="hidden" name="delete" value="y" />
@@ -390,9 +389,8 @@ if ($add_cat && $group_project_id) {
 	<p>
 		<input type="submit" name="post_changes" value="<?php echo _('Permanently delete this subproject and all its data') ?>" />
 	</p>
-	</form>
 	<?php
-
+	echo $HTML->closeForm();
 	pm_footer();
 
 } else {
diff --git a/src/www/project/admin/vhost.php b/src/www/project/admin/vhost.php
index 2305c40..871c160 100644
--- a/src/www/project/admin/vhost.php
+++ b/src/www/project/admin/vhost.php
@@ -4,7 +4,7 @@
  *
  * Portions Copyright 1999-2001 (c) VA Linux Systems
  * The rest Copyright 2002-2004 (c) GForge Team
- * Copyright 2014, Franck Villaume - TrivialDev
+ * Copyright 2014,2016, Franck Villaume - TrivialDev
  * http://fusionforge.org/
  *
  * This file is part of FusionForge. FusionForge is free software;
@@ -118,10 +118,8 @@ print '</p>';
 print '<p>';
 printf(_('Clicking on “Create” will schedule the creation of the Virtual Host.  This will be synced to the project webservers - such that <em>yourhost.org</em> will display the material at <em>%1$s.%2$s</em>.'), $group->getUnixName(), forge_get_config ('web_host'));
 print '</p>';
-
+echo $HTML->openForm(array('name' => 'new_vhost', 'action' => '/project/admin/vhost.php?group_id='.$group->getID().'&createvhost=1', 'method' => 'post'));
 ?>
-
-<form name="new_vhost" action="<?php echo util_make_uri('/project/admin/vhost.php?group_id='.$group->getID().'&createvhost=1'); ?>" method="post">
 <table>
 <tr>
 	<td> <?php echo _('New Virtual Host <em>(e.g. vhost.org)</em>') ?> </td>
@@ -129,10 +127,8 @@ print '</p>';
 	<td> <input type="submit" value="<?php echo _('Create') ?>" /> </td>
 </tr>
 </table>
-</form>
-
 <?php
-
+echo $HTML->closeForm();
 $res_db = db_query_params('
 	SELECT *
 	FROM prweb_vhost

-----------------------------------------------------------------------

Summary of changes:
 src/common/include/Navigation.class.php |  9 ++++---
 src/www/admin/approve-pending.php       | 47 +++++++++++++++++----------------
 src/www/admin/trove/trove_cat_add.php   | 12 ++++-----
 src/www/admin/trove/trove_cat_edit.php  |  8 +++---
 src/www/include/vote_function.php       | 31 ++++++++++------------
 src/www/pm/add_task.php                 | 10 +++----
 src/www/pm/admin/index.php              | 32 +++++++++++-----------
 src/www/project/admin/vhost.php         | 10 +++----
 8 files changed, 72 insertions(+), 87 deletions(-)


hooks/post-receive
-- 
FusionForge



More information about the Fusionforge-commits mailing list