Willkommen Audio Rezepte

Static Copy Extension

The Static Copy Extension is quite cool. I made a few modifications however.

LogoUrl should be just taken as-is

    197   # logo
    198   if ($LogoUrl) {
    199     my $logo = $LogoUrl;
    200     # $logo =~ s|.*/||;           # just the filename
    201     my $alt = T('[Home]');
    202     $header .= $q->img({-src=>$logo, -alt=>$alt, -class=>'logo'}) if $logo;

FooterChange

     20 our ($q, %Page, %IndexHash, $OpenPageName, $ScriptName, $SiteName, $UsePathInfo,
        %Action, $CommentsPrefix, $FreeLinks, $WikiLinks, $LinkPattern, $FreeLinkPattern, 
        $StyleSheet, $StyleSheetPage, $TopLinkBar, $UserGotoBar, $LogoUrl, $SidebarName,
        $FooterNote);
     32 sub DoStatic {
     33   local *StaticOldGetFooterTimestamp = \&GetFooterTimestamp;
     34   local *GetFooterTimestamp = \&StaticNewGetFooterTimestamp;
     35   return unless UserIsAdminOrError();
    227   print $fh $q->div({-class=>'footer'}, $q->hr(), $toolbar,
    228                   $q->span({-class=>'edit'}, $links),
    229                   $q->span({-class=>'time'}, GetFooterTimestamp($id)),
    230                   T($FooterNote));
    231
    347 # override GetFooterTimestamp
    348 sub StaticNewGetFooterTimestamp {
    349   my $id = shift;
    350
    351   my $ts= StaticOldGetFooterTimestamp($id);
    352   #remove time
    353   $ts =~ s/ \d+:\d\d UTC//;
    354   #remove editor
    355   $ts =~ s|by <a.*?/a>||;
    356   # remove diff
    357   $ts =~ s|<a.*?>\(diff\)</a>||;
    358   $ts =~ s|by \d+\.\d+\.\d+\.\d+||;
    359   return $ts
    360 }