Changeset 584
- Timestamp:
- 12/14/04 13:32:21 (4 years ago)
- Location:
- trunk
- Files:
-
- 1 added
- 5 modified
-
Build.PL (modified) (1 diff)
-
Changes (modified) (1 diff)
-
MANIFEST (modified) (1 diff)
-
PREREQUISITES (modified) (1 diff)
-
lib/OpenGuides/Utils.pm (modified) (3 diffs)
-
t/56_diffs_with_macros.t (added)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Build.PL
r582 r584 302 302 $drivers{$dbtype} => 0, 303 303 'File::Spec::Functions' => 0, 304 'File::Temp' => 0, 304 305 'Geography::NationalGrid' => 0, 305 306 'LWP::Simple' => 0, -
trunk/Changes
r581 r584 5 5 Added new CSS class "node_name" for inline non-hyperlink references 6 6 to node names - see README.CSS for details. 7 Fix bug with diff display on nodes containing macros. 7 8 8 9 0.45 1 December 2004 -
trunk/MANIFEST
r562 r584 72 72 t/54_redirect.t 73 73 t/55_node_history.t 74 t/56_diffs_with_macros.t 74 75 t/61_bug_textareas.t 75 76 t/62_bug_os_coords.t -
trunk/PREREQUISITES
r582 r584 23 23 ) 24 24 File::Spec::Functions 25 File::Temp 25 26 ( 26 27 Geography::NationalGrid::GB -
trunk/lib/OpenGuides/Utils.pm
r578 r584 120 120 qr/\@INDEX_LINK\s+\[\[(Category|Locale)\s+([^\]|]+)\|?([^\]]+)?\]\]/ => 121 121 sub { 122 my $wiki = shift; 122 # We may be being called by CGI::Wiki::Plugin::Diff, 123 # which doesn't know it has to pass us $wiki - and 124 # we don't use it anyway. 125 if ( UNIVERSAL::isa( $_[0], "CGI::Wiki" ) ) { 126 shift; # just throw it away 127 } 123 128 my $link_title = $_[2] || "View all pages in $_[0] $_[1]"; 124 129 return qq(<a href="$script_name?action=index;index_type=) . uri_escape(lc($_[0])) . qq(;index_value=) . uri_escape($_[1]) . qq(">$link_title</a>); … … 127 132 sub { 128 133 my ($wiki, $type, $value) = @_; 134 135 # We may be being called by CGI::Wiki::Plugin::Diff, 136 # which doesn't know it has to pass us $wiki 137 unless ( UNIVERSAL::isa( $wiki, "CGI::Wiki" ) ) { 138 return "(unprocessed INDEX_LIST macro)"; 139 } 140 129 141 my @nodes = sort $wiki->list_nodes_by_metadata( 130 142 metadata_type => $type, … … 148 160 }, 149 161 qr/\@RSS\s+(.+)/ => sub { 150 my ($wiki, $url) = @_; 162 # We may be being called by CGI::Wiki::Plugin::Diff, 163 # which doesn't know it has to pass us $wiki - and 164 # we don't use it anyway. 165 if ( UNIVERSAL::isa( $_[0], "CGI::Wiki" ) ) { 166 shift; # just throw it away 167 } 168 169 my $url = shift; 151 170 152 171 # The URL will already have been processed as an inline
