Posted On December 6, 2019

PowerShell: Quick 1-Liner to Check Status of URL

kimconnect 0 comments
blog.KimConnect.com >> Codes >> PowerShell: Quick 1-Liner to Check Status of URL

The kommand:

Invoke-WebRequest "https://blog.kimconnect.com" -MaximumRedirection 0 -ErrorAction SilentlyContinue | Select-Object StatusCode,StatusDescription

Sample Result:

StatusCode StatusDescription
---------- -----------------
200 OK

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

PowerShell: Snippet to Detect and Disconnect Active PS Sessions

# Manual DetectionPS C:\Windows\system32> get-pssession Id Name ComputerName ComputerType State ConfigurationName Availability -- ---- ------------…

PowerShell: connectWinRM Function to Create New-PSSession

This reusable function may be included into PoSh scripts for better connection toward Windows machines…

HTML: Basic Anatomy of A Page

Modern browsers discern the type of documents being loaded; thus, it is necessary to tag…