Why doing it only for flights departing PHL instead of generalizing the system to other airports?
Then things got way better with real browser engines like Webkit that could understand Javascript. That was something that I've personally hacked together as a contractor for an anti-piracy customer using Python, Webkit and Qt framework (PyQt) in around 2009. Shortly after some nice libraries in node/js came out like Phantom.js which would make this much better.
If I were to do this today, I'd use Playwright.