[evolvis-commits] r8510: mail/ is now valid XTHML 1. 0 Transitional↵

mirabilos at evolvis.org mirabilos at evolvis.org
Thu Feb 24 16:44:26 CET 2011


Author: mirabilos
Date: 2011-02-24 16:44:26 +0100 (Thu, 24 Feb 2011)
New Revision: 8510

Modified:
   trunk/gforge_base/evolvisforge-5.1/gforge/ChangeLog
   trunk/gforge_base/evolvisforge-5.1/gforge/www/include/languages/Base.tab
   trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/admin/index.php
   trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/index.php
   trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/mail_utils.php
Log:
mail/ is now valid XTHML 1.0 Transitional


Modified: trunk/gforge_base/evolvisforge-5.1/gforge/ChangeLog
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/ChangeLog	2011-02-24 15:44:23 UTC (rev 8509)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/ChangeLog	2011-02-24 15:44:26 UTC (rev 8510)
@@ -1,37 +1,50 @@
+2003-02-23  Ryan T. Sammartino  <ryants at shaw.ca>
+
+	* www/mail/admin/index.php: valid XHTML 1.0 Transitional.
+	($change_status): order lists alphabetically.
+
+	* www/mail/mail_utils.php: fix errors when no group id specified.
+	Better error checking.
+
+	* www/mail/index.php: valid XHTML 1.0 Transitional.
+
+	* www/include/languages/Base.tab(mail:provided_by): XHTML-ise.
+
+
 2003-02-23  Reinhard Spisser <reinhard at spisser.it>
 
 	* www/account/change_email.php, www/account/change_email-complete.php,
-	www/account/change_pw.php, www/account/first.php, www/account/lostpw.php,	
+	www/account/change_pw.php, www/account/first.php, www/account/lostpw.php,
 	www/account/index.php:
 	finished i18n
-	
+
 	* www/include/languages/Base.tab:
 	added missing strings for /account/
-	
+
 	* www/include/languages/Italian.tab:
 	translation of new strings for /account/
-	
+
 2003-02-22  Reinhard Spisser <reinhard at spisser.it>
 
 	* www/new/index.php, www/include/languages/Base.tab:
 	Committing Reiner Jung's i18n of /new/
-	
+
 	* www/include/languages/Italian.tab:
 	l10n of new strings for /new/
-	
+
 2003-02-21  Reinhard Spisser <reinhard at spisser.it>
 
 	* www/include/vote_function.php:
 	i18n of survey
-	
+
 	* www/survey/*:
 	committing Reiner Jung's i18n of survey
 	some modifications added
-	
+
 	* www/include/languages/Base.tab,
 	www/include/languages/Italian.tab:
 	converted spaces to tabs
-	
+
 	* www/survey/admin/survey_utils.php:
 	added new file
 

Modified: trunk/gforge_base/evolvisforge-5.1/gforge/www/include/languages/Base.tab
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/www/include/languages/Base.tab	2011-02-24 15:44:23 UTC (rev 8509)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/www/include/languages/Base.tab	2011-02-24 15:44:26 UTC (rev 8510)
@@ -504,7 +504,7 @@
 home	registered_users	Registered Users
 home	none_found	None Found
 index	welcome	Welcome
-mail	provided_by	<P>Mailing lists provided via a GForge version of <A href="http://www.list.org">GNU Mailman</A>.  Thanks to the Mailman and <A href="http://www.python.org">Python</A> crews for excellent software.
+mail	provided_by	<p>Mailing lists provided via a GForge version of <a href="http://www.list.org">GNU Mailman</a>.  Thanks to the Mailman and <a href="http://www.python.org">Python</a> crews for excellent software.</p>
 mail	section	Project: $1
 mail	title	Mailing Lists
 mail_admin	section	Mailing Lists

Modified: trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/admin/index.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/admin/index.php	2011-02-24 15:44:23 UTC (rev 8509)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/admin/index.php	2011-02-24 15:44:26 UTC (rev 8510)
@@ -60,7 +60,7 @@
 					} else {
 						$feedback .= " List Added ";
 					}
-			
+
 					// get email addr
 					$res_email = db_query("SELECT email FROM users WHERE user_id='".user_getid()."'");
 					if (db_numrows($res_email) < 1) {
@@ -82,7 +82,7 @@
 					. " -- the ".$GLOBALS['sys_name']." staff\n";
 
 					mail ($row_email['email'],$GLOBALS['sys_name']." New Mailing List",$message,"From: admin@$GLOBALS[sys_default_domain]");
- 
+
 					$feedback .= " Email sent with details to: $row_email[email] ";
 				}
 			} else {
@@ -107,7 +107,7 @@
 			}
 		}
 
-	} 
+	}
 
 	if ($add_list) {
 		/*
@@ -124,12 +124,11 @@
 		$result=db_query("SELECT list_name FROM mail_group_list WHERE group_id='$group_id'");
 		ShowResultSet($result,'Existing Mailing Lists');
 
-		echo 	'<p>
-			<form method="post" action="'.$PHP_SELF.'">
+		echo 	'<form method="post" action="'.$PHP_SELF.'">
 			<input type="hidden" name="post_changes" value="y" />
 			<input type="hidden" name="add_list" value="y" />
 			<input type="hidden" name="group_id" value="'.$group_id.'" />
-			<strong>Mailing List Name:</strong><br />
+			<p><strong>Mailing List Name:</strong><br />
 			<strong>'.group_getunixname($group_id).'-<input type="text" name="list_name" value="" size="10" maxlength="12" />@'.$GLOBALS['sys_lists_host'].'</strong><br /></p>
 			<p>
 			<strong>Is Public?</strong><br />
@@ -141,7 +140,7 @@
 			<strong><span style="color:red">Once created, this list will ALWAYS be attached to your project
 			and cannot be deleted!</span></strong></p>
 			<p>
-			<input type="submit" name="submit" value="Add This List"></p>
+			<input type="submit" name="submit" value="Add This List" /></p>
 			</form>';
 
 		mail_footer(array());
@@ -154,7 +153,8 @@
 
 		$sql="SELECT list_name,group_list_id,is_public,description ".
 			"FROM mail_group_list ".
-			"WHERE group_id='$group_id'";
+			"WHERE group_id='$group_id'".
+			"ORDER BY list_name";
 		$result=db_query($sql);
 		$rows=db_numrows($result);
 
@@ -171,38 +171,39 @@
 			$title_arr=array();
 			$title_arr[]='List';
 			$title_arr[]='Status';
-			$title_arr[]='Update';
-			$title_arr[]='List Admin';
+			$title_arr[]='';
+			$title_arr[]='';
 
 			echo $GLOBALS['HTML']->listTableTop ($title_arr);
 
 			for ($i=0; $i<$rows; $i++) {
 				echo '
 					<tr '. $GLOBALS['HTML']->boxGetAltRowStyle($i) .'><td>'.db_result($result,$i,'list_name').'</td>';
-				echo '
+				echo '<td colspan="3">
 					<form action="'.$PHP_SELF.'" method="post">
 					<input type="hidden" name="post_changes" value="y" />
 					<input type="hidden" name="change_status" value="y" />
 					<input type="hidden" name="group_list_id" value="'.db_result($result,$i,'group_list_id').'" />
 					<input type="hidden" name="group_id" value="'.$group_id.'" />
+					<table width="100%"><tr>
 					<td>
 						<div style="font-size:smaller">
 						<strong>Is Public?</strong><br />
-						<input type="radio" name="is_public" value="1"'.((db_result($result,$i,'is_public')=='1')?' checked=\"checked\"':'').' /> Yes<br />
-						<input type="radio" name="is_public" value="0"'.((db_result($result,$i,'is_public')=='0')?' checked=\"checked\"':'').' /> No<br />
-						<input type="radio" name="is_public" value="9"'.((db_result($result,$i,'is_public')=='9')?' checked=\"checked\"':'').' /> Deleted<br />
-					</div></td><td>
+						<input type="radio" name="is_public" value="1"'.((db_result($result,$i,'is_public')=='1')?' checked="checked"':'').' /> Yes<br />
+						<input type="radio" name="is_public" value="0"'.((db_result($result,$i,'is_public')=='0')?' checked="checked"':'').' /> No<br />
+						<input type="radio" name="is_public" value="9"'.((db_result($result,$i,'is_public')=='9')?' checked="checked"':'').' /> Deleted<br />
+					</div></td><td align="right">
 						<div style="font-size:smaller">
 						<input type="submit" name="submit" value="Update" /></div>
 					</td>
-					<td><a href="https://'. $GLOBALS['sys_lists_host'] .'/mailman/admin/'
+					<td align="center"><a href="https://'. $GLOBALS['sys_lists_host'] .'/mailman/admin/'
 					.db_result($result,$i,'list_name').'">[Administrate this list in GNU Mailman]</a>
 				       </td></tr>
 				       <tr '. $GLOBALS['HTML']->boxGetAltRowStyle($i) .'><td colspan="3">
 				       		<strong>Description:</strong><br />
 						<input type="text" name="description" value="'.
 						db_result($result,$i,'description') .'" size="40" maxlength="80" /><br />
-					</td></tr></form>';
+					</td></tr></table></form></td></tr>';
 			}
 
 			echo $GLOBALS['HTML']->listTableBottom();
@@ -214,15 +215,16 @@
 
 	} else {
 		/*
-			Show main page for choosing 
+			Show main page for choosing
 			either moderotor or delete
 		*/
 		mail_header(array('title'=>'Mailing List Administration','pagename'=>'mail_admin'));
 
 		echo '
 			<p>
-			<a href="'.$PHP_SELF.'?group_id='.$group_id.'&add_list=1">Add Mailing List</a><br />
-			<a href="'.$PHP_SELF.'?group_id='.$group_id.'&change_status=1">Administrate/Update Lists</a>';
+			<a href="'.$PHP_SELF.'?group_id='.$group_id.'&add_list=1">Add Mailing List</a><br />
+			<a href="'.$PHP_SELF.'?group_id='.$group_id.'&change_status=1">Administrate/Update Lists</a>
+			</p>';
 		mail_footer(array());
 	}
 

Modified: trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/index.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/index.php	2011-02-24 15:44:23 UTC (rev 8509)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/index.php	2011-02-24 15:44:26 UTC (rev 8510)
@@ -17,7 +17,7 @@
 if ($group_id) {
 
 	mail_header(array('title'=>'Mailing Lists for '.group_getname($group_id),'pagename'=>'mail','sectionvals'=>array(group_getname($group_id))));
-	
+
 	if (session_loggedin() && user_ismember($group_id)) {
 		$public_flag='0,1';
 	} else {
@@ -28,7 +28,7 @@
 
 	$result = db_query ($sql);
 
-	$rows = db_numrows($result); 
+	$rows = db_numrows($result);
 
 	if (!$result || $rows < 1) {
 		echo '
@@ -51,12 +51,12 @@
 
 	for ($j = 0; $j < $rows; $j++) {
 		echo '<a href="http://'.$GLOBALS['sys_lists_host'].'/pipermail/'.
-			db_result($result, $j, 'list_name').'/">' . 
+			db_result($result, $j, 'list_name').'/">' .
 			html_image("ic/cfolder15.png","15","13",array("border"=>"0")) . '   '.
 			db_result($result, $j, 'list_name').' Archives</a>';
 		echo ' (go to <a href="http://'.$GLOBALS['sys_lists_host'].'/mailman/listinfo/'.
 			db_result($result, $j, 'list_name').'">Subscribe/Unsubscribe/Preferences</a>)<br />';
-		echo ' '.  db_result($result, $j, 'description') .'<p>';
+		echo ' '.  db_result($result, $j, 'description') . '<p />';
 	}
 	echo '</td></tr></table>';
 
@@ -66,6 +66,6 @@
 	echo '
 		<h1>Error - choose a group first</h1>';
 }
-mail_footer(array()); 
+mail_footer(array());
 
 ?>

Modified: trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/mail_utils.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/mail_utils.php	2011-02-24 15:44:23 UTC (rev 8509)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/www/mail/mail_utils.php	2011-02-24 15:44:26 UTC (rev 8510)
@@ -15,20 +15,27 @@
 function mail_header($params) {
 	global $group_id;
 
-	//required for site_project_header
-	$params['group']=$group_id;
-	$params['toptab']='mail';
+	if ($group_id) {
+		//required for site_project_header
+		$params['group']=$group_id;
+		$params['toptab']='mail';
 
-	$project =& group_get_object($group_id);
+		$project =& group_get_object($group_id);
 
-	if (!$project->usesMail()) {
-		exit_error('Error','This Project Has Turned Off Mailing Lists');
-	}
+		if ($project && is_object($project)) {
+			if (!$project->usesMail()) {
+				exit_error('Error','This Project Has Turned Off Mailing Lists');
+			}
+		}
 
 
-	site_project_header($params);
-	echo '
+		site_project_header($params);
+		echo '
 		<p><strong><a href="/mail/admin/?group_id='.$group_id.'">Admin</a></strong></p>';
+	} else {
+		$params['toptab']='mail';
+		site_project_header($params);
+	}
 }
 
 function mail_footer($params) {



More information about the evolvis-commits mailing list