version 1.75, 2003/12/30 22:19:18
|
version 1.80, 2004/01/15 18:25:36
|
Line 275 sub retrieve_author_res_msg {
|
Line 275 sub retrieve_author_res_msg {
|
my $url=shift; |
my $url=shift; |
$url=&Apache::lonnet::declutter($url); |
$url=&Apache::lonnet::declutter($url); |
my ($domain,$author)=($url=~/^(\w+)\/(\w+)\//); |
my ($domain,$author)=($url=~/^(\w+)\/(\w+)\//); |
my %errormsgs=&Apache::lonnet::dump('nohist_res_msgs',$1,$2); |
my %errormsgs=&Apache::lonnet::dump('nohist_res_msgs',$domain,$author); |
my $msgs=''; |
my $msgs=''; |
foreach (keys %errormsgs) { |
foreach (keys %errormsgs) { |
if ($_=~/^\Q$url\E\_\d+$/) { |
if ($_=~/^\Q$url\E\_\d+$/) { |
Line 294 sub retrieve_author_res_msg {
|
Line 294 sub retrieve_author_res_msg {
|
sub del_url_author_res_msg { |
sub del_url_author_res_msg { |
my $url=shift; |
my $url=shift; |
$url=&Apache::lonnet::declutter($url); |
$url=&Apache::lonnet::declutter($url); |
|
my ($domain,$author)=($url=~/^(\w+)\/(\w+)\//); |
|
my @delmsgs=(); |
|
foreach (&Apache::lonnet::getkeys('nohist_res_msgs',$domain,$author)) { |
|
if ($_=~/^\Q$url\E\_\d+$/) { |
|
push (@delmsgs,$_); |
|
} |
|
} |
|
return &Apache::lonnet::del('nohist_res_msgs',\@delmsgs,$domain,$author); |
} |
} |
|
|
# ================= Return hash with URLs for which there is a resource message |
# ================= Return hash with URLs for which there is a resource message |
Line 301 sub del_url_author_res_msg {
|
Line 309 sub del_url_author_res_msg {
|
sub all_url_author_res_msg { |
sub all_url_author_res_msg { |
my ($author,$domain)=@_; |
my ($author,$domain)=@_; |
my %returnhash=(); |
my %returnhash=(); |
foreach (&Apache::lonnet::getkeys('nohist_res_msgs')) { |
foreach (&Apache::lonnet::getkeys('nohist_res_msgs',$domain,$author)) { |
$_=~/^(.+)\_\d+/; |
$_=~/^(.+)\_\d+/; |
$returnhash{$1}=1; |
$returnhash{$1}=1; |
} |
} |
Line 1016 sub handler {
|
Line 1024 sub handler {
|
if (!$ENV{'form.display'}) { |
if (!$ENV{'form.display'}) { |
$r->print('<html><head><title>EMail and Messaging</title>'. |
$r->print('<html><head><title>EMail and Messaging</title>'. |
&Apache::loncommon::studentbrowser_javascript().'</head>'. |
&Apache::loncommon::studentbrowser_javascript().'</head>'. |
&Apache::loncommon::bodytag('EMail and Messages')); |
&Apache::loncommon::bodytag('EMail and Messages'). |
|
&Apache::loncommon::help_open_faq(12). |
|
&Apache::loncommon::help_open_bug('Communication Tools')); |
} |
} |
if ($ENV{'form.display'}) { |
if ($ENV{'form.display'}) { |
my $msgid=$ENV{'form.display'}; |
my $msgid=$ENV{'form.display'}; |
Line 1043 sub handler {
|
Line 1053 sub handler {
|
} |
} |
$r->print(&Apache::loncommon::studentbrowser_javascript(). |
$r->print(&Apache::loncommon::studentbrowser_javascript(). |
'</head>'. |
'</head>'. |
&Apache::loncommon::bodytag('EMail and Messages')); |
&Apache::loncommon::bodytag('EMail and Messages'). |
|
&Apache::loncommon::help_open_faq(12). |
|
&Apache::loncommon::help_open_bug('Communication Tools')); |
$r->print('<b>'.&mt('Subject').':</b> '.$content{'subject'}. |
$r->print('<b>'.&mt('Subject').':</b> '.$content{'subject'}. |
'<br><b>'.&mt('From').':</b> '. |
'<br><b>'.&mt('From').':</b> '. |
&Apache::loncommon::aboutmewrapper( |
&Apache::loncommon::aboutmewrapper( |