/[webpac2]/trunk/vhost/webpac2.cgi
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/vhost/webpac2.cgi

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1171 by dpavlin, Sat Apr 25 22:07:59 2009 UTC revision 1173 by dpavlin, Sat Apr 25 22:26:29 2009 UTC
# Line 76  sub show_pager { Line 76  sub show_pager {
76  }  }
77    
78  my $path = $ENV{PATH_INFO} || 'ecas';  my $path = $ENV{PATH_INFO} || 'ecas';
79    $path =~ s{^/+}{};
80    $path =~ s{/+$}{};
81  my $dir = $0;  my $dir = $0;
82  $dir =~ s{/[^/]+.cgi}{};  $dir =~ s{/[^/]+.cgi}{};
83    
84    dump_yaml( 'dir', $dir );
85    
86  my $config = YAML::LoadFile( "$dir/$path/config.yml" );  my $config = YAML::LoadFile( "$dir/$path/config.yml" );
87    
88  my $database = (keys %{ $config->{databases} })[0];  my $database = (keys %{ $config->{databases} })[0];
# Line 133  foreach ( @{ $db->{input} } ) { Line 137  foreach ( @{ $db->{input} } ) {
137    
138  warn "## only_input = ", dump( $only_input );  warn "## only_input = ", dump( $only_input );
139    
140    my @style = ( '../../style.css' );
141    push @style, "../../$path/$path.css" if -e "$dir/$path/$path.css";
142    dump_yaml( 'style', \@style );
143    
144  print  print
145          start_html(          start_html(
146                  -title => $db->{name},                  -title => $db->{name},
147                  -style => '../../style.css',                  -style => [ @style ],
148          ),          ),
149          h1( $db->{name} ),          h1( $db->{name} ),
150          qq|<div id=description>|, $db->{description}, qq|</div>|,          qq|<div id=description>|, $db->{description}, qq|</div>|,

Legend:
Removed from v.1171  
changed lines
  Added in v.1173

  ViewVC Help
Powered by ViewVC 1.1.26