![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | find all href attributes I want to search all .as?x files for href attributes and produce a sorted distinct list of the attribute values. I'm pretty sure this is easily doable with PowerShell. Any pointers would be greatly appreciated. |
My System Specs![]() |
| | #2 (permalink) |
| | Re: find all href attributes Hi rshillington, Try this, the regex pattern may vary: dir *.as?x | foreach{ $regex = '<a\s+[^>]+?href="(?<href>[^"]+)"' $content = cat $_ [regex]::Matches($content,$regex) | foreach { $_.Groups["href"].Value } } --- Shay Levy Windows PowerShell MVP blog: http://blogs.microsoft.co.il/blogs/ScriptFanatic r> I want to search all .as?x files for href attributes and produce a r> sorted distinct list of the attribute values. I'm pretty sure this r> is easily doable with PowerShell. Any pointers would be greatly r> appreciated. r> |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| batch replace href value | VB Script | |||
| batch replace href value | VB Script | |||
| Fetch special characters like "Ñ" and absolute URL from href attribute of anchors | VB Script | |||
| file attributes | PowerShell | |||
| href Links & Junk Mail | Vista mail | |||