[system] / branches / bw / webwork2 / lib / WeBWorK / Authen.pm Repository:
ViewVC logotype

Diff of /branches/bw/webwork2/lib/WeBWorK/Authen.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 6933 Revision 6934
58 58
59use mod_perl; 59use mod_perl;
60use constant MP2 => ( exists $ENV{MOD_PERL_API_VERSION} and $ENV{MOD_PERL_API_VERSION} >= 2 ); 60use constant MP2 => ( exists $ENV{MOD_PERL_API_VERSION} and $ENV{MOD_PERL_API_VERSION} >= 2 );
61 61
62 62
63#################### 63#####################
64## WeBWorK-tr Import localization handle 64## WeBWorK-tr modification
65## FIXME: we can't import the handle from $WeBWorK::ContentGenerator::LH
66
67use WeBWorK::Localize;
68#$LH = $WeBWorK::LH;
69my $LH = WeBWorK::Localize->get_handle("tr");
70
71## If GENERIC_ERROR_MESSAGE is constant, we can't translate it 65## If GENERIC_ERROR_MESSAGE is constant, we can't translate it
66
72#use vars qw($GENERIC_ERROR_MESSAGE); 67#use vars qw($GENERIC_ERROR_MESSAGE);
73our $GENERIC_ERROR_MESSAGE = ""; # define in new 68our $GENERIC_ERROR_MESSAGE = ""; # define in new
74 69
75## WeBWorK-tr end modification 70## WeBWorK-tr end modification
76##################### 71#####################
72
77 73
78use constant COOKIE_LIFESPAN => 60*60*24*30; # 30 days 74use constant COOKIE_LIFESPAN => 60*60*24*30; # 30 days
79#use constant GENERIC_ERROR_MESSAGE => "Invalid user ID or password."; 75#use constant GENERIC_ERROR_MESSAGE => "Invalid user ID or password.";
80 76
81 77
146 my $class = ref($invocant) || $invocant; 142 my $class = ref($invocant) || $invocant;
147 my $self = { 143 my $self = {
148 r => $r, 144 r => $r,
149 }; 145 };
150 #initialize 146 #initialize
151 $GENERIC_ERROR_MESSAGE = $LH->maketext("Invalid user ID or password."); 147 $GENERIC_ERROR_MESSAGE = $r->maketext("Invalid user ID or password.");
152 bless $self, $class; 148 bless $self, $class;
153 return $self; 149 return $self;
154} 150}
155 151
156=back 152=back

Legend:
Removed from v.6933  
changed lines
  Added in v.6934

aubreyja at gmail dot com
ViewVC Help
Powered by ViewVC 1.0.9