I have a specific Windows 7 machine that needs to always display a specific Intranet page. (it shows an internal status page in kiosk mode).
If this machine every loses connectivity to the web server, unfortunately, the browser shows the typical "web page could not be retrieved" error message and it never recovers. I need to manually reload the page when the connection is restored.
I'm thinking if it would be possible to write a PowerShell script that checks the connectivity/availability of the Intranet page and if it detects an error, it would launch a browser that points to a local file html file which would say something more professional and graceful like "site temporarily down for maintenance." Also, if the PowerShell script could run on a regular interval, when the Intranet page becomes available again, it would close the browser that is showing the maintenance page and start showing the page with the original Intranet site.
For the Intranet site checking, I was looking at the invoke-webrequest: as the mechanism.
Any guidance would be appreciated as I am new to PowerShell.