diff Lib/IMPL/Web/QueryHandler/PageFormat.pm @ 64:259cd3df6e53

Doc generation Minor fixes
author wizard
date Mon, 15 Mar 2010 17:45:13 +0300
parents 76b878ad6596
children 2840c4c85db8
line wrap: on
line diff
--- a/Lib/IMPL/Web/QueryHandler/PageFormat.pm	Mon Mar 15 02:38:09 2010 +0300
+++ b/Lib/IMPL/Web/QueryHandler/PageFormat.pm	Mon Mar 15 17:45:13 2010 +0300
@@ -1,5 +1,5 @@
 package IMPL::Web::QueryHandler::PageFormat;
-use base qw(IMPL::Web::QueryHandler);
+use base qw(IMPL::Web::QueryHandler IMPL::Object::Autofill);
 
 __PACKAGE__->PassThroughArgs;
 
@@ -7,13 +7,23 @@
 use IMPL::Web::TDocument;
 use Error qw(:try);
 
+BEGIN {
+	public property charsetTemplates => prop_all;
+}
+
+sub CTOR {
+	my ($this) = @_;
+	
+	$this->charsetTemplates('utf-8') unless $this->charsetTemplates;
+}
+
 sub Process {
 	my ($this,$action,$nextHandler) = @_;
 	
 	my $doc = new IMPL::Web::TDocument();
 	
 	try {
-		$doc->loadFile ( $ENV{PATH_TRANSLATED}, 'cp1251' );
+		$doc->loadFile ( $ENV{PATH_TRANSLATED}, $this->charsetTemplates );
 		
 		$action->response->contentType('text/html');
 		my $hOut = $action->response->streamBody;