17.2. Testing and Validating Web Sites

Downloading content from a remote server is only the beginning. We have to do something with that content afterward. You can use what you have learned so far to build various utilities that periodically download newer versions of given pages or crawl a web site to find and report broken links. This section will demonstrate extracting pieces of information from web pages' HTML code that we can use later.

17.2.1. Test-Url: Verifying a Page's Existence

Here is an interesting problem: how do we verify that a page or a file exists on a remote server? If we could do that, we could use it to create scripts that run periodically making sure that important files are accessible from the Web. We can also check a ...

Get Pro Windows PowerShell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.