[LON-CAPA-cvs] cvs: loncom /interface londocs.pm
www
www@source.lon-capa.org
Sat, 04 Dec 2010 16:17:27 -0000
www Sat Dec 4 16:17:27 2010 EDT
Modified files:
/loncom/interface londocs.pm
Log:
Cleanup: subroutine inside subroutine?
Index: loncom/interface/londocs.pm
diff -u loncom/interface/londocs.pm:1.440 loncom/interface/londocs.pm:1.441
--- loncom/interface/londocs.pm:1.440 Sun Nov 28 00:04:05 2010
+++ loncom/interface/londocs.pm Sat Dec 4 16:17:27 2010
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Documents
#
-# $Id: londocs.pm,v 1.440 2010/11/28 00:04:05 raeburn Exp $
+# $Id: londocs.pm,v 1.441 2010/12/04 16:17:27 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -2610,7 +2610,24 @@
bug=>'Instructor Interface'});
}
+# subroutine to list form elements
+sub create_list_elements {
+ my @formarr = @_;
+ my $list = '';
+ for my $button (@formarr){
+ for my $picture(keys %$button) {
+ $list .= &Apache::lonhtmlcommon::htmltag('li', $picture.' '.$button->{$picture}, {class => 'LC_menubuttons_inline_text'});
+ }
+ }
+ return $list;
+}
+# subroutine to create ul from list elements
+sub create_form_ul {
+ my $list = shift;
+ my $ul = &Apache::lonhtmlcommon::htmltag('ul',$list, {class => 'LC_ListStyleNormal'});
+ return $ul;
+}
sub handler {
@@ -2749,26 +2766,6 @@
}
}
-# subroutine to list form elements
-sub create_list_elements {
- my @formarr = @_;
- my $list = '';
- for my $button (@formarr){
- for my $picture(keys %$button) {
- #my $link = Apache::lonhtmlcommon::htmltag('a' ,$button->{$picture}, {href => "test"});
- $list .= Apache::lonhtmlcommon::htmltag('li', $picture.' '.$button->{$picture}, {class => 'LC_menubuttons_inline_text'});
- }
- }
- return $list;
-}
-
-# subroutine to create ul from list elements
-sub create_form_ul {
- my $list = shift;
- my $ul = Apache::lonhtmlcommon::htmltag('ul',$list, {class => 'LC_ListStyleNormal'});
- return $ul;
-}
-
# get course data
my $coursenum=$env{'course.'.$env{'request.course.id'}.'.num'};
my $coursedom=$env{'course.'.$env{'request.course.id'}.'.domain'};