really use default logo if the agent-specific one isn't found
authorivan <ivan>
Thu, 6 Oct 2005 23:09:39 +0000 (23:09 +0000)
committerivan <ivan>
Thu, 6 Oct 2005 23:09:39 +0000 (23:09 +0000)
httemplate/view/cust_bill-logo.cgi

index 96471ff..235485f 100755 (executable)
@@ -1,15 +1,15 @@
 <%
 
+my $conf = new FS::Conf;
+
 my($query) = $cgi->keywords;
 $query =~ /^([^\.\/]*)$/;
 my $templatename = $1;
-if ( $templatename && $conf->exists("${logo}_$templatename.png") ) {
+if ( $templatename && $conf->exists("logo_$templatename.png") ) {
   $templatename = "_$templatename";
 } else {
   $templatename = '';
 }
 
-my $conf = new FS::Conf;
-
 http_header('Content-Type' => 'image/png' );
 %><%= $conf->config_binary("logo$templatename.png") %>