diff options
| author | mark <mark> | 2011-09-16 00:15:48 +0000 |
|---|---|---|
| committer | mark <mark> | 2011-09-16 00:15:48 +0000 |
| commit | 9c866ccad0f187f29d21f12b93f15f2787aa9843 (patch) | |
| tree | f1a17825d748de59b6d578f5510ab2bb9e6a43bb /httemplate/config/config-image.cgi | |
| parent | 2e9b97a7492a06855cc55a65f4df7b14607a0db9 (diff) | |
invoice template and config localization, #12367
Diffstat (limited to 'httemplate/config/config-image.cgi')
| -rw-r--r-- | httemplate/config/config-image.cgi | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/httemplate/config/config-image.cgi b/httemplate/config/config-image.cgi index 0de9d4278..0e04ab5bc 100644 --- a/httemplate/config/config-image.cgi +++ b/httemplate/config/config-image.cgi @@ -4,8 +4,6 @@ die "access denied" unless $FS::CurrentUser::CurrentUser->access_right('Configuration'); -my $conf = new FS::Conf; - http_header( 'Content-Type' => 'image/png' ); #just png for now $cgi->param('key') =~ /^([-\w.]+)$/ or die "illegal config option"; @@ -16,6 +14,13 @@ if ( $cgi->param('agentnum') =~ /^(\d+)$/ ) { $agentnum = $1; } +my $locale = ''; +if ( $cgi->param('locale') =~ /^(\w+)$/ ) { + $locale = $1; +} + +my $conf = new FS::Conf { 'locale' => $locale }; + my $logo = $conf->config_binary($name, $agentnum); $logo = eps2png($logo) if $name =~ /\.eps$/i; |
