Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Finding dates from web pages

by talexb (Chancellor)
on Feb 25, 2020 at 13:18 UTC ( [id://11113399]=note: print w/replies, xml ) Need Help??


in reply to Finding dates from web pages

Can you get what you want just from doing a HEAD on the web page? That would give you the Last Updated date, I think. I'm not sure if that's exactly what you want.

Alex / talexb / Toronto

Thanks PJ. We owe you so much. Groklaw -- RIP -- 2003 to 2013.

Replies are listed 'Best First'.
Re^2: Finding dates from web pages
by cormanaz (Deacon) on Feb 25, 2020 at 20:39 UTC
    That works for some pages that have known meta fields like pubdate or time, but many web pages don't use them. I think the Python library applies some heuristics in such cases.

      "I think the Python library applies some heuristics in such cases"

      You could look at the Python code and implement the same thing in perl. Let me know if you get stuck.

        Looking at the code, that would appear to be quite an undertaking. It turns out it can be installed and run from the command line, so I will probably just go that route, though it will slow things down to load it every time it needs to be run.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11113399]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (4)
As of 2024-04-16 22:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found