3 ms·
In case anybody would like to view the source, see below (via PowerShell[0]): $Post = Invoke-WebRequest -URI "https://news.ycombinator.com/item?id=31883209
by Natfan 4y ago
In case anybody would like to view the source, see below (via PowerShell[0]):
$Post = Invoke-WebRequest -URI "https://news.ycombinator.com/item?id=31883209" -UseBasicParsing
$Link = $Post.Links.Where{$_.href -like "https://easylang.online/run/?code=*"}.href
$EncodedCode = $Link -replace "https://easylang.online/run/\?code=(.+)",'$1'
$Code = [Web.HTTPUtility]::URLDecode($EncodedCode)
Write-Output $Code
[0]: https://github.com/PowerShell/PowerShell https://github.com/PowerShell/PowerShell, note that Windows PowerShell 5.x is installed on most Windows systems by default.
- chkas 4y agoOr you click on "Code" on the web page.