File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# !/usr/local/bin/perl
22# Add index anchors to source file _and_ generate index database
33# Arnaud Le Hors - lehors@w3.org
4- # $Id: addianch,v 2.0 1998-02-02 18:52:27 bbos Exp $
4+ # $Id: addianch,v 2.1 1998-02-02 20:10:02 bbos Exp $
55
66use Getopt::Std;
77use lib ' bin' ;
@@ -48,7 +48,7 @@ while ($buf =~ /$defp/sio) {
4848 print OUTPUT $` ;
4949 $buf = $' ;
5050 $elem = $& ;
51- $content = $3 ;
51+ $content = $4 ;
5252 $class = $2 ;
5353
5454 # Check if there is a title attribute, otherwise use content
@@ -62,7 +62,7 @@ while ($buf =~ /$defp/sio) {
6262 @entries = split (/ \| /o , cleanup($entry ));
6363
6464 # Create an anchor
65- if ($content =~ / <a\b [^>]*?name\s *=\s *[\"\' ]?([^\s\"\' >]*?)[\"\' ]?/sio ) {
65+ if ($content =~ / <a\s + [^>]*?name\s *=\s *[\"\' ]?([^\s\"\' >]*?)[\"\' ]?/sio ) {
6666 # Already a name in the content, re-use it
6767 $anchor = $1 ;
6868 print OUTPUT $elem ;
Original file line number Diff line number Diff line change 11# !/usr/local/bin/perl
22# Add index anchors to source file _and_ generate index database
33# Arnaud Le Hors - lehors@w3.org
4- # $Id: addianch,v 2.0 1998-02-02 18:52:27 bbos Exp $
4+ # $Id: addianch,v 2.1 1998-02-02 20:10:02 bbos Exp $
55
66use Getopt::Std;
77use lib ' bin' ;
@@ -48,7 +48,7 @@ while ($buf =~ /$defp/sio) {
4848 print OUTPUT $` ;
4949 $buf = $' ;
5050 $elem = $& ;
51- $content = $3 ;
51+ $content = $4 ;
5252 $class = $2 ;
5353
5454 # Check if there is a title attribute, otherwise use content
@@ -62,7 +62,7 @@ while ($buf =~ /$defp/sio) {
6262 @entries = split (/ \| /o , cleanup($entry ));
6363
6464 # Create an anchor
65- if ($content =~ / <a\b [^>]*?name\s *=\s *[\"\' ]?([^\s\"\' >]*?)[\"\' ]?/sio ) {
65+ if ($content =~ / <a\s + [^>]*?name\s *=\s *[\"\' ]?([^\s\"\' >]*?)[\"\' ]?/sio ) {
6666 # Already a name in the content, re-use it
6767 $anchor = $1 ;
6868 print OUTPUT $elem ;
You can’t perform that action at this time.
0 commit comments