[LON-CAPA-cvs] cvs: loncom /interface lonsimplepage.pm lontemplate.pm

amueller amueller@source.lon-capa.org
Fri, 20 Feb 2009 15:09:28 -0000


amueller		Fri Feb 20 15:09:28 2009 EDT

  Modified files:              
    /loncom/interface	lonsimplepage.pm lontemplate.pm 
  Log:
  The title section of simple page is now in a Box which uses the LC_ContentBoxSpecial Style. The fieldset with the action links for the user are now on the top of the page.
  
Index: loncom/interface/lonsimplepage.pm
diff -u loncom/interface/lonsimplepage.pm:1.67 loncom/interface/lonsimplepage.pm:1.68
--- loncom/interface/lonsimplepage.pm:1.67	Thu Feb 19 17:32:39 2009
+++ loncom/interface/lonsimplepage.pm	Fri Feb 20 15:09:28 2009
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Simple Page Editor
 #
-# $Id: lonsimplepage.pm,v 1.67 2009/02/19 17:32:39 neumanie Exp $
+# $Id: lonsimplepage.pm,v 1.68 2009/02/20 15:09:28 amueller Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -305,8 +305,11 @@
 		      '<form method="post"><input type="submit" name="delupl" value="'.&mt('Delete Photo').'" />' );
 	}	
 	if($allowed){
-                $r->print($image.'<div class="clear">&nbsp;</div>');
+               $r->print($image.'<div class="clear">&nbsp;</div>');
        }
+#	if(!$allowed){
+#		$r-print($image);
+#	}
 	
 	foreach my $field (sort(keys(%syllabusfields))) {
 	    if (($syllabus{$field}) || ($allowed) || 
@@ -332,21 +335,24 @@
 			if($allowed){
 				$r->print('<p>');
 			}
-                        $r->print('<h1>'.$message.'</h1>');
+                        $r->print('<h2>'.$message.'</h2>');
                     } else {
                         my $safeinit;
                         $r->print(&Apache::lonxml::xmlparse($r,'tex','<h1>'.$message.'</h1>'));
                     }
                     if ($allowed) {
                         if ($env{'form.grade_target'} ne 'tex') {
-                            $r->print('<br /><h3>'.&mt('Title').'</h3>');
+                            #$r->print('<br /><h3>'.&mt('Title').'</h3>');
+			    &Apache::lontemplate::print_template($r, &mt('Title'), $message, $allowed, 'LC_ContentBoxSpecial'); 
 			    &Apache::lontemplate::print_editbox_template($r,$syllabus{$field},$field);				
 			    $r->print('</p>');
                         } else {
                             my $safeinit;
                             $r->print(&Apache::lonxml::xmlparse($r,'tex',$syllabus{$field},$safeinit));
                         }
-                    }
+                    } 
+#		    if ($allowed) { $r->print($image . '<div class="clear">&nbsp; </div>'); }
+		    if(!$allowed) {$r->print($image); } 
                 } else {
 		    if ($target ne 'tex') {
 			if($allowed){
@@ -370,10 +376,10 @@
 		}
 	    }
 	}
-	
-	if(!$allowed){
-		$r->print($image);
-	}	
+	#MUEA: Stand hier if???
+#	if(!$allowed){ 
+#		$r->print($image);
+#	}	
 	if ($allowed && ($env{'form.grade_target'} ne 'tex')) {
 	    $r->print(&Apache::lonhtmlcommon::htmlareaselectactive
 		      ('bbb_content').'</form>');
Index: loncom/interface/lontemplate.pm
diff -u loncom/interface/lontemplate.pm:1.17 loncom/interface/lontemplate.pm:1.18
--- loncom/interface/lontemplate.pm:1.17	Thu Feb 19 17:32:39 2009
+++ loncom/interface/lontemplate.pm	Fri Feb 20 15:09:28 2009
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # "Template" Functions to generate html output
 #
-# $Id: lontemplate.pm,v 1.17 2009/02/19 17:32:39 neumanie Exp $
+# $Id: lontemplate.pm,v 1.18 2009/02/20 15:09:28 amueller Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -126,7 +126,8 @@
 	my ($r,$topic,$content, $allowed,$boxclass) = @_;	
 	$r->print('<div class="'.$boxclass.'">');	
 	$r->print('<h4 class="LC_hcell">'.$topic.'</h4>');
-	$r->print('<blockquote>'.$content.'</blockquote>');
+#	$r->print('<blockquote>'.$content.'</blockquote>');
+	$r->print('<p>' .$content . '</p>');
 	$r->print('</div>');
 }
 
@@ -142,12 +143,13 @@
 {
 	my($r)=@_;
 	#TODO add translation for Functions
-	$r->print('<fieldset><legend>Functions</legend>');
+	$r->print('<fieldset><legend>'. &mt('Functions') . '</legend>');
 }
 sub print_functions_content
 {
 	my($r,$content) = @_;
 	$r->print($content.'&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp');
+	
 }
 sub print_end_page_functions
 {