Ignore leading spaces/tabs when extracting a title from HTML files.
This commit is contained in:
parent
1ede072465
commit
b4fc73806b
1 changed files with 1 additions and 1 deletions
|
|
@ -102,7 +102,7 @@ fn get_html_title {
|
||||||
|
|
||||||
# As a backup we might want to pick the first 'non-tag' text in the file with:
|
# As a backup we might want to pick the first 'non-tag' text in the file with:
|
||||||
if(~ $"t '')
|
if(~ $"t '')
|
||||||
t=`{sed -n -e 's/^(<[^>]+>)*([^<]+).*/\2/p; 32q' < $1 | sed 1q}
|
t=`{sed -n -e 's/^[ ]*(<[^>]+>)*([^<]+).*/\2/p; 32q' < $1 | sed 1q}
|
||||||
|
|
||||||
echo $t
|
echo $t
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue