Skip to content

Commit

Permalink
add .html if no extension
Browse files Browse the repository at this point in the history
  • Loading branch information
youpy committed Apr 3, 2012
1 parent 0fbc0eb commit 0cfbca2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions webiblo.pl
Expand Up @@ -88,6 +88,7 @@ sub get_content {
my $fragment = $uri->fragment;

$file =~ s/\..+/.html/ unless $file =~ /\.html$/;
$file .= '.html' unless $file =~ /\.html$/; # add .html if no extension
$object->{file} = $file;
$object->{href} = $fragment ? "$file#$fragment" : $file;

Expand Down

0 comments on commit 0cfbca2

Please sign in to comment.