Browse Source

[svn r20369] Style Changes - Implemented Alignment content of test, assignment and forum in view of lp - FS#4160

Cristian Fasanando 16 years ago
parent
commit
63c2f51ce3

+ 4 - 3
main/exercice/exercice_submit.php

@@ -1,5 +1,5 @@
 <?php
-// $Id: exercice_submit.php 20357 2009-05-06 03:54:49Z cvargas1 $
+// $Id: exercice_submit.php 20369 2009-05-06 16:12:55Z cfasanando $
 
 /*
 ==============================================================================
@@ -43,7 +43,7 @@
 *	@package dokeos.exercise
 * 	@author Olivier Brouckaert
 * 	@author Julio Montoya multiple fill in blank option added
-* 	@version $Id: exercice_submit.php 20357 2009-05-06 03:54:49Z cvargas1 $
+* 	@version $Id: exercice_submit.php 20369 2009-05-06 16:12:55Z cfasanando $
 */
 
 include ('exercise.class.php');
@@ -143,6 +143,7 @@ if ($origin == 'learnpath' && isset ($_GET['not_multiple_attempt']) && $_GET['no
 	$not_multiple_attempt = (int) $_GET['not_multiple_attempt'];
 	if ($not_multiple_attempt === 1) {
 		include_once ('../inc/reduced_header.inc.php');
+		echo '<div style="height:10px">&nbsp;</div>';
 		Display :: display_warning_message(get_lang('ReachedOneAttempt'));
 		exit;
 	}
@@ -888,7 +889,7 @@ if ($origin != 'learnpath') { //so we are not in learnpath tool
 		//if there was no valid iso-code, use the english one
 		$document_language = 'en';
 	}
-
+	echo '<div style="height:10px">&nbsp;</div>';
 	/*
 	 * HTML HEADER
 	 */

+ 15 - 10
main/forum/forumfunction.inc.php

@@ -3285,18 +3285,23 @@ function display_forum_search_results($search_term) {
  */
 function search_link() {
 	global $origin;
-	$return = '<a href="forumsearch.php?'.api_get_cidreq().'&action=search&origin='.$origin.'"> '.Display::return_icon('search.gif', get_lang('Search')).' '.get_lang('Search').'</a>';
-	if (!empty($_GET['search'])) {
-		$return .= ': '.Security::remove_XSS($_GET['search']).' ';
-		$url = api_get_self().'?';
-		foreach ($_GET as $key=>$value) {
-			if ($key<>'search') {
-				$url_parameter[]=Security::remove_XSS($key).'='.Security::remove_XSS($value);
+	
+	$return = '';
+	
+	if ($origin != 'learnpath') {
+		$return = '<a href="forumsearch.php?'.api_get_cidreq().'&action=search&origin='.$origin.'"> '.Display::return_icon('search.gif', get_lang('Search')).' '.get_lang('Search').'</a>';
+		if (!empty($_GET['search'])) {
+			$return .= ': '.Security::remove_XSS($_GET['search']).' ';
+			$url = api_get_self().'?';
+			foreach ($_GET as $key=>$value) {
+				if ($key<>'search') {
+					$url_parameter[]=Security::remove_XSS($key).'='.Security::remove_XSS($value);
+				}
 			}
+			$url = $url.implode('&amp;',$url_parameter);
+			$return .= '<a href="'.$url.'">'.Display::return_icon('delete.gif', get_lang('RemoveSearchResults')).'</a>';
 		}
-		$url = $url.implode('&amp;',$url_parameter);
-		$return .= '<a href="'.$url.'">'.Display::return_icon('delete.gif', get_lang('RemoveSearchResults')).'</a>';
-	}
+	} 
 	return $return;
 }
 /**

+ 10 - 7
main/forum/reply.php

@@ -199,13 +199,16 @@ if (!$_user['user_id'] AND $current_forum['allow_anonymous']==0) {
 	Action links
 -----------------------------------------------------------
 */
-
-echo '<div class="actions">';
-echo '<span style="float:right;">'.search_link().'</span>';
-echo '<a href="index.php?gradebook='.$gradebook.'">'.Display::return_icon('back.png').' '.get_lang('BackToForumOverview').'</a>';
-echo '<a href="viewforum.php?forum='.Security::remove_XSS($_GET['forum']).'">'.Display::return_icon('forum.gif').' '.get_lang('BackToForum').'</a>';
-echo '<a href="viewthread.php?forum='.Security::remove_XSS($_GET['forum']).'&amp;gradebook='.$gradebook.'&amp;thread='.Security::remove_XSS($_GET['thread']).'">'.Display::return_icon('forumthread.gif').' '.get_lang('BackToThread').'</a>';
-echo '</div>';
+if ($origin != 'learnpath') {
+	echo '<div class="actions">';
+	echo '<span style="float:right;">'.search_link().'</span>';
+	echo '<a href="index.php?gradebook='.$gradebook.'">'.Display::return_icon('back.png').' '.get_lang('BackToForumOverview').'</a>';
+	echo '<a href="viewforum.php?forum='.Security::remove_XSS($_GET['forum']).'">'.Display::return_icon('forum.gif').' '.get_lang('BackToForum').'</a>';
+	echo '<a href="viewthread.php?forum='.Security::remove_XSS($_GET['forum']).'&amp;gradebook='.$gradebook.'&amp;thread='.Security::remove_XSS($_GET['thread']).'">'.Display::return_icon('forumthread.gif').' '.get_lang('BackToThread').'</a>';
+	echo '</div>';
+} else {
+	echo '<div style="height:15px">&nbsp;</div>';
+}
 /*
 -----------------------------------------------------------
 	Display Forum Category and the Forum information

+ 13 - 8
main/forum/viewforum.php

@@ -292,6 +292,9 @@ if (!api_is_allowed_to_edit(false,true) AND ($current_forum_category['visibility
 	forum_not_allowed_here();
 }
 
+if ($origin == 'learnpath') {
+	echo '<div style="height:15px">&nbsp;</div>';
+}
 
 /*
 -----------------------------------------------------------
@@ -435,13 +438,15 @@ if(is_array($threads)) {
 			// get attach id
 			$attachment_list=get_attachment($row['post_id']);
 			$id_attach = !empty($attachment_list)?$attachment_list['id']:'';
-							
-			if (api_is_allowed_to_edit(false,true) && !(api_is_course_coach() && $current_forum['session_id']!=$_SESSION['id_session'])) {
-				echo "<a href=\"editpost.php?".api_get_cidreq()."&forum=".Security::remove_XSS($my_forum)."&amp;thread=".Security::remove_XSS($row['thread_id'])."&amp;post=".$row['post_id']."&amp;gidReq=".$_SESSION['toolgroup']."&origin=".$origin."&id_attach=".$id_attach."\">".icon('../img/edit.gif',get_lang('Edit'))."</a>\n";
-				echo "<a href=\"".api_get_self()."?".api_get_cidreq()."&forum=".Security::remove_XSS($my_forum)."&amp;action=delete&amp;content=thread&amp;gidReq=".$_SESSION['toolgroup']."&amp;id=".$row['thread_id'].$origin_string."\" onclick=\"javascript:if(!confirm('".addslashes(htmlentities(get_lang("DeleteCompleteThread"),ENT_QUOTES,$charset))."')) return false;\">".icon('../img/delete.gif',get_lang('Delete'))."</a>";
-				display_visible_invisible_icon('thread', $row['thread_id'], $row['visibility'], array("forum"=>$my_forum,'origin'=>$origin,"gidReq"=>$_SESSION['toolgroup']));
-				display_lock_unlock_icon('thread',$row['thread_id'], $row['locked'], array("forum"=>$my_forum,'origin'=>$origin,"gidReq"=>$_SESSION['toolgroup']));
-				echo "<a href=\"viewforum.php?".api_get_cidreq()."&forum=".Security::remove_XSS($my_forum)."&amp;action=move&amp;gidReq=".$_SESSION['toolgroup']."&amp;thread=".$row['thread_id'].$origin_string."\">".icon('../img/deplacer_fichier.gif',get_lang('MoveThread'))."</a>";
+
+			if ($origin != 'learnpath') {							
+				if (api_is_allowed_to_edit(false,true) && !(api_is_course_coach() && $current_forum['session_id']!=$_SESSION['id_session'])) {
+					echo "<a href=\"editpost.php?".api_get_cidreq()."&forum=".Security::remove_XSS($my_forum)."&amp;thread=".Security::remove_XSS($row['thread_id'])."&amp;post=".$row['post_id']."&amp;gidReq=".$_SESSION['toolgroup']."&origin=".$origin."&id_attach=".$id_attach."\">".icon('../img/edit.gif',get_lang('Edit'))."</a>\n";
+					echo "<a href=\"".api_get_self()."?".api_get_cidreq()."&forum=".Security::remove_XSS($my_forum)."&amp;action=delete&amp;content=thread&amp;gidReq=".$_SESSION['toolgroup']."&amp;id=".$row['thread_id'].$origin_string."\" onclick=\"javascript:if(!confirm('".addslashes(htmlentities(get_lang("DeleteCompleteThread"),ENT_QUOTES,$charset))."')) return false;\">".icon('../img/delete.gif',get_lang('Delete'))."</a>";
+					display_visible_invisible_icon('thread', $row['thread_id'], $row['visibility'], array("forum"=>$my_forum,'origin'=>$origin,"gidReq"=>$_SESSION['toolgroup']));
+					display_lock_unlock_icon('thread',$row['thread_id'], $row['locked'], array("forum"=>$my_forum,'origin'=>$origin,"gidReq"=>$_SESSION['toolgroup']));
+					echo "<a href=\"viewforum.php?".api_get_cidreq()."&forum=".Security::remove_XSS($my_forum)."&amp;action=move&amp;gidReq=".$_SESSION['toolgroup']."&amp;thread=".$row['thread_id'].$origin_string."\">".icon('../img/deplacer_fichier.gif',get_lang('MoveThread'))."</a>";
+				}
 			}
 			$iconnotify = 'send_mail.gif';
 			if (is_array(isset($_SESSION['forum_notification']['thread'])?$_SESSION['forum_notification']['thread']:null)) {
@@ -451,7 +456,7 @@ if(is_array($threads)) {
 			}
 			$icon_liststd = 'group.gif';
 			echo "<a href=\"".api_get_self()."?".api_get_cidreq()."&amp;forum=".Security::remove_XSS($my_forum)."&origin=".$origin."&amp;action=notify&amp;content=thread&amp;gidReq=".$_SESSION['toolgroup']."&amp;id=".$row['thread_id']."\">".icon('../img/'.$iconnotify,get_lang('NotifyMe'))."</a>";
-			if (api_is_allowed_to_edit()) {
+			if (api_is_allowed_to_edit() && $origin != 'learnpath') {
 				echo '<a href="'.api_get_self().'?'.api_get_cidreq().'&amp;forum='.Security::remove_XSS($my_forum).'&origin='.$origin.'&amp;action=liststd&amp;content=thread&amp;gidReq='.$_SESSION['toolgroup'].'&amp;id='.$row['thread_id'].'">'.icon('../img/'.$icon_liststd,get_lang('StudentList')).'</a>';			
 			}
 			echo "</td>\n";

+ 14 - 8
main/forum/viewthread.php

@@ -186,11 +186,15 @@ if ($my_message<>'PostDeletedSpecial') {
 		Action Links
 	-----------------------------------------------------------
 	*/
+	if ($origin=='learnpath') {
+		echo '<div style="height:15px">&nbsp;</div>';
+	}
 	echo '<div class="actions">';
 	echo '<span style="float:right;">'.search_link().'</span>';
-	echo '<a href="index.php?gradebook='.$gradebook.'">'.Display::return_icon('back.png').' '.get_lang('BackToForumOverview').'</a>';
-	echo '<a href="viewforum.php?forum='.Security::remove_XSS($_GET['forum']).'">'.Display::return_icon('forum.gif').' '.get_lang('BackToForum').'</a>';
-
+	if ($origin != 'learnpath') {
+		echo '<a href="index.php?gradebook='.$gradebook.'">'.Display::return_icon('back.png').' '.get_lang('BackToForumOverview').'</a>';
+		echo '<a href="viewforum.php?forum='.Security::remove_XSS($_GET['forum']).'">'.Display::return_icon('forum.gif').' '.get_lang('BackToForum').'</a>';
+	}
 	// the reply to thread link should only appear when the forum_category is not locked AND the forum is not locked AND the thread is not locked.
 	// if one of the three levels is locked then the link should not be displayed
 	if ($current_forum_category['locked']==0 AND $current_forum['locked']==0 AND $current_thread['locked']==0 OR api_is_allowed_to_edit(false,true)) {
@@ -216,11 +220,13 @@ if ($my_message<>'PostDeletedSpecial') {
 		}
 	}
 	
-	// the different views of the thread
-	$my_url = '<a href="viewthread.php?'.api_get_cidreq().'&amp;forum='.Security::remove_XSS($_GET['forum']).'&amp;origin='.$origin.'&amp;gradebook='.$gradebook.'&amp;thread='.Security::remove_XSS($_GET['thread']).'&amp;search='.Security::remove_XSS(urlencode($my_search));
-	echo $my_url.'&amp;view=flat&origin='.$origin.'&amp;gradebook='.$gradebook.'">'.Display::return_icon('forum_listview.gif').get_lang('FlatView').'</a>';
-	echo $my_url.'&amp;view=threaded&origin='.$origin.'"&amp;gradebook='.$gradebook.'">'.Display::return_icon('forum_threadedview.gif').get_lang('ThreadedView').'</a>';
-	echo $my_url.'&amp;view=nested&origin='.$origin.'"&gradebook='.$gradebook.'">'.Display::return_icon('forum_nestedview.gif').get_lang('NestedView').'</a>';
+	// the different views of the thread	
+	if ($origin != 'learnpath') {
+		$my_url = '<a href="viewthread.php?'.api_get_cidreq().'&amp;forum='.Security::remove_XSS($_GET['forum']).'&amp;origin='.$origin.'&amp;gradebook='.$gradebook.'&amp;thread='.Security::remove_XSS($_GET['thread']).'&amp;search='.Security::remove_XSS(urlencode($my_search));
+		echo $my_url.'&amp;view=flat&origin='.$origin.'&amp;gradebook='.$gradebook.'">'.Display::return_icon('forum_listview.gif').get_lang('FlatView').'</a>';
+		echo $my_url.'&amp;view=threaded&origin='.$origin.'"&amp;gradebook='.$gradebook.'">'.Display::return_icon('forum_threadedview.gif').get_lang('ThreadedView').'</a>';
+		echo $my_url.'&amp;view=nested&origin='.$origin.'"&gradebook='.$gradebook.'">'.Display::return_icon('forum_nestedview.gif').get_lang('NestedView').'</a>';
+	}
 	$my_url = null;	
 	
 	echo '</div>&nbsp;';

+ 11 - 8
main/forum/viewthread_flat.inc.php

@@ -69,19 +69,22 @@ foreach ($rows as $row) {
 	if (($current_forum['allow_edit']==1 AND $row['user_id']==$_user['user_id']) or (api_is_allowed_to_edit(false,true)  && !(api_is_course_coach() && $current_forum['session_id']!=$_SESSION['id_session']))) {
 		echo "<a href=\"editpost.php?".api_get_cidreq()."&forum=".Security::remove_XSS($_GET['forum'])."&amp;thread=".Security::remove_XSS($_GET['thread'])."&amp;post=".$row['post_id']."&origin=".$origin."&edit=edition&id_attach=".$id_attach."\">".icon('../img/edit.gif',get_lang('Edit'))."</a>\n";
 	}
-	if (api_is_allowed_to_edit(false,true)  && !(api_is_course_coach() && $current_forum['session_id']!=$_SESSION['id_session'])) {
-		echo "<a href=\"".api_get_self()."?".api_get_cidreq()."&forum=".Security::remove_XSS($_GET['forum'])."&amp;thread=".Security::remove_XSS($_GET['thread'])."&amp;action=delete&amp;content=post&amp;id=".$row['post_id']."&origin=".$origin."\" onclick=\"javascript:if(!confirm('".addslashes(htmlentities(get_lang("DeletePost"),ENT_QUOTES,$charset))."')) return false;\">".icon('../img/delete.gif',get_lang('Delete'))."</a>\n";
-		display_visible_invisible_icon('post', $row['post_id'], $row['visible'],array('forum'=>Security::remove_XSS($_GET['forum']),'thread'=>Security::remove_XSS($_GET['thread']), 'origin'=>$origin ));
-		echo "\n";
-		if ($increment>0) {
-			echo "<a href=\"viewthread.php?".api_get_cidreq()."&forum=".Security::remove_XSS($_GET['forum'])."&amp;thread=".Security::remove_XSS($_GET['thread'])."&amp;action=move&amp;post=".$row['post_id']."&origin=".$origin."\">".icon('../img/deplacer_fichier.gif',get_lang('MovePost'))."</a>";
-		}
+	
+	if ($origin != 'learnpath') {
+		if (api_is_allowed_to_edit(false,true)  && !(api_is_course_coach() && $current_forum['session_id']!=$_SESSION['id_session'])) {
+			echo "<a href=\"".api_get_self()."?".api_get_cidreq()."&forum=".Security::remove_XSS($_GET['forum'])."&amp;thread=".Security::remove_XSS($_GET['thread'])."&amp;action=delete&amp;content=post&amp;id=".$row['post_id']."&origin=".$origin."\" onclick=\"javascript:if(!confirm('".addslashes(htmlentities(get_lang("DeletePost"),ENT_QUOTES,$charset))."')) return false;\">".icon('../img/delete.gif',get_lang('Delete'))."</a>\n";
+			display_visible_invisible_icon('post', $row['post_id'], $row['visible'],array('forum'=>Security::remove_XSS($_GET['forum']),'thread'=>Security::remove_XSS($_GET['thread']), 'origin'=>$origin ));
+			echo "\n";
+			if ($increment>0) {
+				echo "<a href=\"viewthread.php?".api_get_cidreq()."&forum=".Security::remove_XSS($_GET['forum'])."&amp;thread=".Security::remove_XSS($_GET['thread'])."&amp;action=move&amp;post=".$row['post_id']."&origin=".$origin."\">".icon('../img/deplacer_fichier.gif',get_lang('MovePost'))."</a>";
+			}
+		}	
 	}
 	
 	$userinf=api_get_user_info($row['user_id']);
 	$user_status=api_get_status_of_user_in_course($row['user_id'],api_get_course_id());
 	$current_qualify_thread=show_qualify('1',$_GET['cidReq'],$_GET['forum'],$row['poster_id'],$_GET['thread']);
-	if (api_is_allowed_to_edit()) {
+	if (api_is_allowed_to_edit() && $origin != 'learnpath') {
 		if( isset($_GET['gradebook'])){
 			if ($increment>0 && $user_status!=1 ) {
 				$info_thread=get_thread_information(Security::remove_XSS($_GET['thread']));

+ 21 - 17
main/work/work.lib.php

@@ -1,4 +1,4 @@
-<?php //$Id: work.lib.php 20250 2009-05-01 14:52:02Z iflorespaz $
+<?php //$Id: work.lib.php 20369 2009-05-06 16:12:55Z cfasanando $
 /* For licensing terms, see /dokeos_license.txt */
 /**
 *	@package dokeos.work
@@ -6,7 +6,7 @@
 * 	@author Patrick Cool <patrick.cool@UGent.be>, Ghent University - ability for course admins to specify wether uploaded documents are visible or invisible by default.
 * 	@author Roan Embrechts, code refactoring and virtual course support
 * 	@author Frederic Vauthier, directories management
-* 	@version $Id: work.lib.php 20250 2009-05-01 14:52:02Z iflorespaz $
+* 	@version $Id: work.lib.php 20369 2009-05-06 16:12:55Z cfasanando $
 */
 /**
  * Displays action links (for admins, authorized groups members and authorized students)
@@ -35,7 +35,7 @@ function display_action_links($cur_dir_path, $always_show_tool_options, $always_
 			echo '<a href="work.php?gradebook='.$gradebook.'">'.Display::return_icon('back.png').' '.get_lang('BackToWorksList').'</a>';
 		}
 	}
-	if (! $always_show_tool_options && api_is_allowed_to_edit()) {
+	if (! $always_show_tool_options && api_is_allowed_to_edit() && $origin != 'learnpath') {
 		// Create dir		
 		$display_output .=	'<a href="'.api_get_self().'?'.api_get_cidreq().'&amp;toolgroup='.Security::remove_XSS($_GET['toolgroup']).'&amp;curdirpath='.$cur_dir_path.'&amp;createdir=1&origin='.$origin.'&gradebook='.$gradebook.'"><img src="../img/folder_new.gif" border="0" alt="'.get_lang('CreateDir').'" title ="'.get_lang('CreateDir').'" /> '.get_lang('CreateAssignment').' </a>';
 		// Options
@@ -48,7 +48,7 @@ function display_action_links($cur_dir_path, $always_show_tool_options, $always_
 							
 	}
 	
-	if (api_is_allowed_to_edit())
+	if (api_is_allowed_to_edit() && $origin != 'learnpath')
 	{
 		// delete all files
 		$display_output .= 	"<a href=\"".api_get_self()."?".api_get_cidreq()."&amp;curdirpath=".$cur_dir_path."&amp;origin=$origin&amp;gradebook=$gradebook&amp;delete=all\" ".
@@ -320,12 +320,14 @@ function display_student_publications_list($work_dir,$sub_course_dir,$currentCou
 	
 	$table_header[] = array(get_lang('Date'),true);
 	
-	if( $is_allowed_to_edit) {
-	$table_header[] = array(get_lang('Modify'),true);
-	}
+	if ($origin != 'learnpath') {		
+		if ($is_allowed_to_edit) {
+		$table_header[] = array(get_lang('Modify'),true);
+		}
+		$table_header[] = array('RealDate',false);
+	}	
+	
 	
-	$table_header[] = array('RealDate',false);
-		
 	// An array with the setting of the columns -> 1: columns that we will show, 0:columns that will be hide 
 	$column_show[]=1; // type
 	$column_show[]=1; // title
@@ -336,7 +338,7 @@ function display_student_publications_list($work_dir,$sub_course_dir,$currentCou
 
 	$column_show[]=1; //date
 	
-	if( $is_allowed_to_edit) {
+	if( $is_allowed_to_edit && $origin != 'learnpath') {
 		$column_show[]=1; //modify
 	}
 	
@@ -633,13 +635,15 @@ function display_student_publications_list($work_dir,$sub_course_dir,$currentCou
 			$row[]='';			
 		}	
 		
-		if( $is_allowed_to_edit) {
-			$action .= '<a href="'.api_get_self().'?cidReq='.api_get_course_id().
-				'&curdirpath='.$my_sub_dir.'&origin='.$origin.'&gradebook='.$gradebook.'&edit_dir='.$mydir.'"><img src="../img/edit.gif" alt="'.get_lang('Modify').'" title="'.get_lang('Modify').'"></a>';						
-			$action .= '<a href="'.api_get_self().'?'.api_get_cidreq().'&origin='.$origin.'&gradebook='.$gradebook.'&delete_dir='.$mydir.'&delete2='.$id2.'" onclick="javascript:if(!confirm('."'".addslashes(htmlentities(get_lang('ConfirmYourChoice'),ENT_QUOTES,$charset))."'".')) return false;" title="'.get_lang('DirDelete').'"  ><img src="'.api_get_path(WEB_IMG_PATH).'delete.gif" alt="'.get_lang('DirDelete').'" title="'.get_lang('DirDelete').'"></a>';
-			$row[] = $action;
-		} else {
-			$row[] = "";
+		if ($origin != 'learnpath') {
+			if( $is_allowed_to_edit) {
+				$action .= '<a href="'.api_get_self().'?cidReq='.api_get_course_id().
+					'&curdirpath='.$my_sub_dir.'&origin='.$origin.'&gradebook='.$gradebook.'&edit_dir='.$mydir.'"><img src="../img/edit.gif" alt="'.get_lang('Modify').'" title="'.get_lang('Modify').'"></a>';						
+				$action .= '<a href="'.api_get_self().'?'.api_get_cidreq().'&origin='.$origin.'&gradebook='.$gradebook.'&delete_dir='.$mydir.'&delete2='.$id2.'" onclick="javascript:if(!confirm('."'".addslashes(htmlentities(get_lang('ConfirmYourChoice'),ENT_QUOTES,$charset))."'".')) return false;" title="'.get_lang('DirDelete').'"  ><img src="'.api_get_path(WEB_IMG_PATH).'delete.gif" alt="'.get_lang('DirDelete').'" title="'.get_lang('DirDelete').'"></a>';
+				$row[] = $action;
+			} else {
+				$row[] = "";
+			}
 		}		
 		$table_data[] = $row;
 	}

+ 14 - 6
main/work/work.php

@@ -1,4 +1,4 @@
-<?php //$Id: work.php 20250 2009-05-01 14:52:02Z iflorespaz $
+<?php //$Id: work.php 20369 2009-05-06 16:12:55Z cfasanando $
 /* For licensing terms, see /dokeos_license.txt */
 /**
 *	@package dokeos.work
@@ -6,7 +6,7 @@
 * 	@author Patrick Cool <patrick.cool@UGent.be>, Ghent University - ability for course admins to specify wether uploaded documents are visible or invisible by default.
 * 	@author Roan Embrechts, code refactoring and virtual course support
 * 	@author Frederic Vauthier, directories management
-*  	@version $Id: work.php 20250 2009-05-01 14:52:02Z iflorespaz $
+*  	@version $Id: work.php 20369 2009-05-06 16:12:55Z cfasanando $
 *
 * 	@todo refactor more code into functions, use quickforms, coding standards, ...
 */
@@ -403,6 +403,10 @@ if (!empty ($_POST['changeProperties'])) {
 
 // introduction section
 
+if ($origin=='learnpath') {
+	echo '<div style="height:15px">&nbsp;</div>';
+}
+
 $fck_attribute['Width'] = '100%';
 $fck_attribute['Height'] = '300';
 $fck_attribute['ToolbarSet'] = 'Introduction';
@@ -1396,10 +1400,14 @@ if (!$display_upload_form && !$display_tool_options) {
 		isset($_GET['cidreq'])?$cidreq = Security::Remove_XSS($_GET['cidreq']):$cidreq='';
 		isset($_GET['curdirpath'])?$curdirpath = Security::Remove_XSS($_GET['curdirpath']):$curdirpath='';
 		isset($_REQUEST['filter'])?$filter = (int)$_REQUEST['filter']:$filter='';
-		$form_filter = '<form method="post" action="'.api_get_self().'?cidReq='.$cidreq.'&curdirpath='.$curdirpath.'&gradebook='.$gradebook.'">';
-		$form_filter .= make_select('filter',array(0=>get_lang('SelectAFilter'),1=>get_lang('FilterByNotRevised'),2=>get_lang('FilterByRevised'),3=>get_lang('FilterByNotExpired')),$filter);
-		$form_filter .= '<input type="submit" value="'.get_lang('FilterAssignments').'"</form>';
-		echo $form_filter;
+		
+		if ($origin != 'learnpath') {
+			$form_filter = '<form method="post" action="'.api_get_self().'?cidReq='.$cidreq.'&curdirpath='.$curdirpath.'&gradebook='.$gradebook.'">';
+			$form_filter .= make_select('filter',array(0=>get_lang('SelectAFilter'),1=>get_lang('FilterByNotRevised'),2=>get_lang('FilterByRevised'),3=>get_lang('FilterByNotExpired')),$filter);
+			$form_filter .= '<input type="submit" value="'.get_lang('FilterAssignments').'"</form>';
+			echo $form_filter;
+		}
+		
 	} 
 	display_student_publications_list($base_work_dir . '/' . $my_cur_dir_path, 'work/' . $my_cur_dir_path, $currentCourseRepositoryWeb, $link_target_parameter, $dateFormatLong, $origin,$add_query);
 }