version 1.37, 2003/02/13 16:31:54
|
version 1.40, 2003/02/20 01:35:27
|
Line 108 sub success {
|
Line 108 sub success {
|
if ($httpbrowser=~/win/i) { $clientos='win'; } |
if ($httpbrowser=~/win/i) { $clientos='win'; } |
if ($httpbrowser=~/embed/i) { $clientos='pda'; } |
if ($httpbrowser=~/embed/i) { $clientos='pda'; } |
|
|
|
# -------------------------------------- Any accessibility options to remember? |
|
if (($FORM{'interface'}) && ($FORM{'remember'} eq 'true')) { |
|
foreach ('imagesuppress','appletsuppress', |
|
'embedsuppress','fontenhance','blackwhite') { |
|
if ($FORM{$_} eq 'true') { |
|
&Apache::lonnet::put('environment',{$_ => 'on'},$domain,$username); |
|
} else { |
|
&Apache::lonnet::del('environment',[$_],$domain,$username); |
|
} |
|
} |
|
} |
# ------------------------------------------------------------- Get environment |
# ------------------------------------------------------------- Get environment |
|
|
my $userenv; |
my $userenv; |
Line 118 sub success {
|
Line 129 sub success {
|
$userenv.="environment.$key=$userenv{$key}\n"; |
$userenv.="environment.$key=$userenv{$key}\n"; |
} |
} |
} |
} |
|
if (($userenv{'interface'}) && (!$FORM{'interface'})) { |
|
$FORM{'interface'}=$userenv{'interface'}; |
|
} |
# --------------------------------------------------------- Write first profile |
# --------------------------------------------------------- Write first profile |
|
|
{ |
{ |
Line 143 sub success {
|
Line 157 sub success {
|
print $idf "request.role=cm\n"; |
print $idf "request.role=cm\n"; |
print $idf "request.host=$ENV{'HTTP_HOST'}\n"; |
print $idf "request.host=$ENV{'HTTP_HOST'}\n"; |
if ($FORM{'interface'}) { |
if ($FORM{'interface'}) { |
$FORM{'interface'}=~s/\W//gs; |
$FORM{'interface'}=~s/\W//gs; |
print $idf "browser.interface=$FORM{'interface'}\n"; |
print $idf "browser.interface=$FORM{'interface'}\n"; |
$ENV{'browser.interface'}=$FORM{'interface'}; |
$ENV{'browser.interface'}=$FORM{'interface'}; |
} |
foreach |
|
('imagesuppress','appletsuppress', |
|
'embedsuppress','fontenhance','blackwhite') { |
|
if (($FORM{$_} eq 'true') || |
|
($userenv{$_} eq 'on')) { |
|
print $idf "browser.$_=on\n"; |
|
} |
|
|
|
} |
|
} |
if ($userroles ne '') { print $idf "$userroles"; } |
if ($userroles ne '') { print $idf "$userroles"; } |
$idf->close(); |
$idf->close(); |
} |
} |