[Fusionforge-commits] r10837 - in trunk/src: common/forum common/include common/tracker www/export www/forum/include www/pm/admin www/scm www/stats www/tracker

Roland Mas lolando at libremir.placard.fr.eu.org
Mon Oct 4 15:53:28 CEST 2010


Author: lolando
Date: 2010-10-04 15:53:27 +0200 (Mon, 04 Oct 2010)
New Revision: 10837

Modified:
   trunk/src/common/forum/ForumMessageFactory.class.php
   trunk/src/common/include/User.class.php
   trunk/src/common/tracker/ArtifactQuery.class.php
   trunk/src/www/export/rss20_forum.php
   trunk/src/www/export/rss20_tasks.php
   trunk/src/www/forum/include/ForumHTML.class.php
   trunk/src/www/pm/admin/index.php
   trunk/src/www/scm/viewvc.php
   trunk/src/www/stats/site_stats_utils.php
   trunk/src/www/tracker/query.php
   trunk/src/www/tracker/tracker.php
Log:
Merged from Evolvis: PHP warnings

Modified: trunk/src/common/forum/ForumMessageFactory.class.php
===================================================================
--- trunk/src/common/forum/ForumMessageFactory.class.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/common/forum/ForumMessageFactory.class.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -182,7 +182,7 @@
 		$this->fetched_rows=$rows;
 		if (!$result || $rows < 1) {
 			$this->setError('No Messages Found '.db_error());
-			return false;
+			$this->forum_messages = false;
 		} else {
 			while ($arr = db_fetch_array($result)) {
 				$this->forum_messages[] = new ForumMessage($this->Forum, $arr['msg_id'], $arr);

Modified: trunk/src/common/include/User.class.php
===================================================================
--- trunk/src/common/include/User.class.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/common/include/User.class.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -108,7 +108,7 @@
 		//
 		//  See if this ID already has been fetched in the cache
 		//
-		if (!$id_arr[$i]) {
+		if (!isset($id_arr[$i]) || !$id_arr[$i]) {
 			continue;
 		}
 		if (!isset($USER_OBJ["_".$id_arr[$i]."_"])) {

Modified: trunk/src/common/tracker/ArtifactQuery.class.php
===================================================================
--- trunk/src/common/tracker/ArtifactQuery.class.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/common/tracker/ArtifactQuery.class.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -499,6 +499,8 @@
 	 *	@return	string	The column name.
 	 */
 	function getSortCol() {
+		if (!isset($this->element_array))
+			return false;
 		return $this->element_array[ARTIFACT_QUERY_SORTCOL][0];
 	}
 
@@ -508,6 +510,8 @@
 	 *	@return	string	ASC or DESC
 	 */
 	function getSortOrd() {
+		if (!isset($this->element_array))
+			return false;
 		return $this->element_array[ARTIFACT_QUERY_SORTORD][0];
 	}
 
@@ -517,6 +521,8 @@
 	 *	@return	string	mod date range.
 	 */
 	function getModDateRange() {
+		if (!isset($this->element_array))
+			return false;
 		if ($this->element_array[ARTIFACT_QUERY_MODDATE][0]) {
 			return $this->element_array[ARTIFACT_QUERY_MODDATE][0];
 		} else {
@@ -530,6 +536,8 @@
 	 *	@return	string	Open date range.
 	 */
 	function getOpenDateRange() {
+		if (!isset($this->element_array))
+			return false;
 		if ($this->element_array[ARTIFACT_QUERY_OPENDATE][0]) {
 			return $this->element_array[ARTIFACT_QUERY_OPENDATE][0];
 		} else {
@@ -543,6 +551,8 @@
 	 *	@return	string	Close date range.
 	 */
 	function getCloseDateRange() {
+		if (!isset($this->element_array))
+			return false;
 		if ($this->element_array[ARTIFACT_QUERY_CLOSEDATE][0]) {
 			return $this->element_array[ARTIFACT_QUERY_CLOSEDATE][0];
 		} else {
@@ -595,6 +605,8 @@
 	 *	@return	string	Assignee ID
 	 */
 	function getAssignee() {
+		if (!isset($this->element_array))
+			return false;
 		return $this->element_array[ARTIFACT_QUERY_ASSIGNEE][0];
 	}
 
@@ -604,6 +616,8 @@
 	 *	@return	string	Status ID
 	 */
 	function getStatus() {
+		if (!isset($this->element_array))
+			return false;
 		return $this->element_array[ARTIFACT_QUERY_STATE][0];
 	}
 

Modified: trunk/src/www/export/rss20_forum.php
===================================================================
--- trunk/src/www/export/rss20_forum.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/export/rss20_forum.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -167,8 +167,8 @@
 //there were filter parameters but they were invalid or
 //there were valid group_ids, but they contained no forums
 
-if (($n_groups == 0 && count($_GET['group_ids'])>0) || 
-    ($n_forums == 0 && count($_GET['forum_ids'])>0) ||
+if (($n_groups == 0 && isset($_GET['group_ids']) && count($_GET['group_ids'])>0) || 
+    ($n_forums == 0 && isset($_GET['forum_ids']) && count($_GET['forum_ids'])>0) ||
     ($n_groups > 0 && $n_forums == 0)){
     $error_no_messages = "No forum messages found. Please check for invalid parameters and if the project(s) contain public forums.";
 }

Modified: trunk/src/www/export/rss20_tasks.php
===================================================================
--- trunk/src/www/export/rss20_tasks.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/export/rss20_tasks.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -71,6 +71,7 @@
 }
 $p=handle_getvar('group_project_ids');
 $projects = array_unique(array_merge($projects,$p)); //die projekte der getvars kommen dazu
+$project_sq = '' ;
 if(isset($projects[0]))
 {
 	foreach($projects AS $project)

Modified: trunk/src/www/forum/include/ForumHTML.class.php
===================================================================
--- trunk/src/www/forum/include/ForumHTML.class.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/forum/include/ForumHTML.class.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -406,6 +406,9 @@
 		*/
 		global $total_rows,$forum_id,$current_message,$group_id;
 
+		if (!isset($msg_arr["$msg_id"]))
+			return "";
+
 		$rows=count($msg_arr["$msg_id"]);
 		$ret_val = "";
 		//echo "<p>ShowSubmessages() $msg_id | $rows";

Modified: trunk/src/www/pm/admin/index.php
===================================================================
--- trunk/src/www/pm/admin/index.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/pm/admin/index.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -53,6 +53,8 @@
 $delete = getStringFromRequest('delete');
 $id = getIntFromRequest('id');
 
+$feedback = '' ;
+
 if (getStringFromRequest('post_changes')) {
 	/*
 		Update the database

Modified: trunk/src/www/scm/viewvc.php
===================================================================
--- trunk/src/www/scm/viewvc.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/scm/viewvc.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -43,6 +43,7 @@
 }
 
 // Get the project name from query
+$projectName = "";
 if(getStringFromGet('root') && strpos(getStringFromGet('root'), ';') === false) {
 	$projectName = getStringFromGet('root');
 } else {

Modified: trunk/src/www/stats/site_stats_utils.php
===================================================================
--- trunk/src/www/stats/site_stats_utils.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/stats/site_stats_utils.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -440,7 +440,7 @@
 		while ( $row = db_fetch_array($res) ) {
 			$i++;
 
-			print	'<tr ' . $GLOBALS['HTML']->boxGetAltRowStyle($i) . 'align="right">'
+			print	'<tr ' . $GLOBALS['HTML']->boxGetAltRowStyle($i) . ' align="right">'
 				. '<td>' . $row['month'] . '</td>'
 				. '<td>' . number_format( $row["site_page_views"],0 ) . '</td>'
 				. '<td>' . number_format( $row["subdomain_views"],0 ) . '</td>'

Modified: trunk/src/www/tracker/query.php
===================================================================
--- trunk/src/www/tracker/query.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/tracker/query.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -26,6 +26,7 @@
 	exit_not_logged_in();
 }
 
+$feedback = '' ;
 
 $query_id = getIntFromRequest('query_id');
 $query_action = getIntFromRequest('query_action');

Modified: trunk/src/www/tracker/tracker.php
===================================================================
--- trunk/src/www/tracker/tracker.php	2010-10-04 13:53:16 UTC (rev 10836)
+++ trunk/src/www/tracker/tracker.php	2010-10-04 13:53:27 UTC (rev 10837)
@@ -53,6 +53,7 @@
 		exit_error($ath->getErrorMessage(),'tracker');
 	}
 }
+$feedback = '' ;
 switch (getStringFromRequest('func')) {
 
 	case 'add' : {




More information about the Fusionforge-commits mailing list