Diff for /loncom/interface/loncommon.pm between versions 1.545 and 1.548

version 1.545, 2007/07/03 23:02:53 version 1.548, 2007/07/11 20:32:15
Line 2457  sub preferred_languages { Line 2457  sub preferred_languages {
     split(/\s*(\,|\;|\:)\s*/,$env{'environment.languages'}));      split(/\s*(\,|\;|\:)\s*/,$env{'environment.languages'}));
     }      }
     my $browser=(split(/\;/,$ENV{'HTTP_ACCEPT_LANGUAGE'}))[0];      my $browser=(split(/\;/,$ENV{'HTTP_ACCEPT_LANGUAGE'}))[0];
     &Apache::lonnet::logthis($browser);  
     if ($browser) {      if ($browser) {
  @languages=(@languages,split(/\s*(\,|\;|\:)\s*/,$browser));   @languages=(@languages,split(/\s*(\,|\;|\:)\s*/,$browser));
     }      }
Line 4438  span.LC_nobreak { Line 4437  span.LC_nobreak {
   
 table.LC_docs_documents {  table.LC_docs_documents {
   background: #BBBBBB;    background: #BBBBBB;
   border-size: 0px;    border-width: 0px;
   border-collapse: collapse;    border-collapse: collapse;
 }  }
   
Line 4481  table.LC_docs_documents td.LC_docs_docum Line 4480  table.LC_docs_documents td.LC_docs_docum
   color: #990000;    color: #990000;
 }  }
   
   .LC_docs_reinit_warn,
   .LC_docs_ext_edit {
     font-size: x-small;
   }
   
 .LC_docs_editor td.LC_docs_entry_title,  .LC_docs_editor td.LC_docs_entry_title,
 .LC_docs_editor td.LC_docs_entry_icon {  .LC_docs_editor td.LC_docs_entry_icon {
   background: #FFFFBB;    background: #FFFFBB;
Line 4935  sub simple_error_page { Line 4939  sub simple_error_page {
     }      }
 }  }
   
   =pod
   
   =item * &inhibit_menu_check($arg)
   
   Checks for a inhibitmenu state and generates output to preserve it
   
   Inputs:         $arg - can be any of
                        - undef - in which case the return value is a string 
                                  to add  into arguments list of a uri
                        - 'input' - in which case the return value is a HTML
                                    <form> <input> field of type hidden to
                                    preserve the value
                        - a url - in which case the return value is the url with
                                  the neccesary cgi args added to preserve the
                                  inhibitmenu state
                        - a ref to a url - no return value, but the string is
                                           updated to include the neccessary cgi
                                           args to preserve the inhibitmenu state
   
   =cut
   
   sub inhibit_menu_check {
       my ($arg) = @_;
       &get_unprocessed_cgi($ENV{'QUERY_STRING'}, ['inhibitmenu']);
       if ($arg eq 'input') {
    if ($env{'form.inhibitmenu'}) {
       return '<input type="hidden" name="inhibitmenu" value="'.$env{'form.inhibitmenu'}.'" />';
    } else {
       return
    }
       }
       if ($env{'form.inhibitmenu'}) {
    if (ref($arg)) {
       $$arg .= '?inhibitmenu='.$env{'form.inhibitmenu'};
    } elsif ($arg eq '') {
       $arg .= 'inhibitmenu='.$env{'form.inhibitmenu'};
    } else {
       $arg .= '?inhibitmenu='.$env{'form.inhibitmenu'};
    }
       }
       if (!ref($arg)) {
    return $arg;
       }
   }
   
 ###############################################  ###############################################
   
 =pod  =pod

Removed from v.1.545  
changed lines
  Added in v.1.548


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>