Public/Get-Dirkjan.ps1
function Get-Dirkjan { Invoke-WebRequest -Uri 'https://dirkjan.nl' | Select-Object -ExpandProperty Links | Select-Object -ExpandProperty HRef | Where-Object { $_ -like 'https://dirkjan.nl/cartoon/*' } | ForEach-Object { $Url = $_ $DateText = ($Url -split '/')[-2] $DateText = ($DateText -split '_')[0] $Date = [DateTime]::ParseExact($DateText, 'yyyyMMdd', $null) $Src = Invoke-WebRequest -Uri $Url | Select-Object -ExpandProperty Images | Select-Object -Skip 1 -First 1 | Select-Object -ExpandProperty Src [PSCustomObject][Ordered]@{ PSTypeName = 'UncommonSense.Dirkjan.Article' Url = $Url Date = $Date Title = 'Dirkjan' Body = $Src } } } |