Re: [webmin-devel] Block of code

"Jamie Cameron" <[email protected]> Mon, 18 Mar 2013 21:31:28 -0700 (PDT)
Newsgroups gmane.comp.web.webmin.devel
Message-ID <[email protected]>
Can you give us more details about what is going wrong with this
code exactly?

On 18/Mar/2013 13:20 Emma wasanzy <[email protected]> wrote ..
> Hello,
> 
> Can anyone tell me what the problem with this part of code. Is part of the
> webmin module am writing for tomcat.
> 
> 
> if ( $instance eq "tomcat5" ){
>     if ( $log_type eq "catalina.out") {
>         if ( $num_day eq "current" ) {
>             $tomcat_log = "/var/log/tomcat5/catalina.out";
>         }
>         else {
>             $tomcat_log = "/var/log/tomcat5/catalina.out-$day.gz";
>         }
>     }
>     elsif ( $log_type eq "access_log" ) {
>         if ( $num_day eq "current") {
>             $tomcat_log =
> "/var/log/tomcat5/access-logs/tomcat_access.log-$current";
>         }
>         else {
>             $tomcat_log =
> "/var/log/tomcat5/access-logs/tomcat_access.log-$inday.gz";
>         }
>     }
> }
> else {
>     if ( $log_type eq "catalina.out" ) {
>         if ( $num_day eq "current" ) {
>             $tomcat_log = "/var/lib/$instance/logs/catalina.out";
>         }
>         else {
>             $tomcat_log = "/var/lib/$instance/logs/catalina.out-$day.gz";
>         }
>     }
>     elsif ($log_type eq "access_log" ) {
>         if ( $num_day eq "current") {
>             $tomcat_log =
> "/var/lib/$instance/access-logs/tomcat_access.log-$current";
>         }
>         else {
>             $tomcat_log =
> "/var/lib/$instance/access-logs/tomcat_access.log-$inday.gz";
>         }
>     }
> }

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_mar
-
Forwarded by the Webmin development list at [email protected]
To remove yourself from this list, go to
http://lists.sourceforge.net/lists/listinfo/webadmin-devel