summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph Graham <joseph@fibreglass.tunachunks>2013-09-24 10:02:31 +0100
committerJoseph Graham <joseph@fibreglass.tunachunks>2013-09-24 10:02:31 +0100
commita13736b6fe15d7d7d050bb1fb2e5519271658795 (patch)
treec20ae8d8d398cd734565394c83b210efe383264b
parentd451906a78ac2f6379f8284d27b4996b433614da (diff)
Made him find page title even if the html uses all caps in tag names
-rw-r--r--hack_of_all_hacks24
1 files changed, 12 insertions, 12 deletions
diff --git a/hack_of_all_hacks b/hack_of_all_hacks
index 11d1962..b92610f 100644
--- a/hack_of_all_hacks
+++ b/hack_of_all_hacks
@@ -170,18 +170,18 @@ EOF
url_to_get="${BASH_REMATCH}"
# If pbot is not present.
- if true #grep no pbot_present > /dev/null
- then
- the_title=$(
- curl -L --compressed "${url_to_get}" 2> /dev/null |
- while rdom
- do
- if [[ ${element} = title ]]
- then
- sed 's/ / /g' <<< "${content}" | replace_wierd_html_chars
- fi
- done
- )
+ if true #grep no pbot_present > /dev/null
+ then
+ the_title=$(
+ curl -L --compressed "${url_to_get}" 2> /dev/null |
+ while rdom
+ do
+ if [[ ${element} = title ]] || [[ ${element} = TITLE ]]
+ then
+ sed 's/ / /g' <<< "${content}" | replace_wierd_html_chars
+ fi
+ done
+ )
if ! [[ -z ${the_title} ]]
then