(Powershell noob here) I'm attempting to write a script to delete every /SitePages/Results.aspx file in the farm, but only for SubSites. So far i've got this, which gives me each site in the farm, but i only want to do this on subsites.
$sites= Get-SPSite -WebApplication $url|Where-Object{$_.Url -like"$url/sites/*"} foreach($site in $sites){ # Delete fuctions here. }I'd really like to build this script on my own but i wont argue with anyone that just happens to have this already built. :)