Annotation of rat/lonwrapper.pm, revision 1.2
1.1 www 1: # The LearningOnline Network with CAPA
2: # Wrapper for external and binary files as standalone resources
3: #
4: # (Edit Handler for RAT Maps
5: # (TeX Content Handler
6: #
7: # 05/29/00,05/30 Gerd Kortemeyer)
8: # 7/1,6/30 Gerd Kortemeyer)
9: #
10: # 7/5 Gerd Kortemeyer
11:
12: package Apache::lonwrapper;
13:
14: use strict;
15: use Apache::Constants qw(:common);
1.2 ! www 16: use Apache::lonnet();
! 17: use Apache::lonxml();
1.1 www 18:
19: # ================================================================ Main Handler
20:
21: sub handler {
22: my $r=shift;
23: $r->content_type('text/html');
24: $r->send_http_header;
25:
26: return OK if $r->header_only;
27:
28: my $url=$r->uri;
1.2 ! www 29: $url=~s/^\/adm\/wrapper//;
! 30: my $events='onLoad="'.&Apache::lonxml::loadevents.
! 31: '" onUnload="'.&Apache::lonxml::unloadevents.'"';
! 32: my $script=&Apache::lonxml::registerurl(1);
1.1 www 33: $r->print(<<ENDDOCUMENT);
34: <html>
35: <head>
1.2 ! www 36: $script
1.1 www 37: </head>
1.2 ! www 38: <frameset rows="1,*" border=0 $events>
! 39: <frame src="/adm/rat/empty.html">
1.1 www 40: <frame src="$url">
41: </frameset>
42: </html>
43: ENDDOCUMENT
44: return OK;
45: }
46:
47: 1;
48: __END__
49:
50:
51:
52:
53:
54:
55:
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>