Question: I have yet to find out how to disable this new web 2.0+ irritant. What business is it of the website vendor, whether **it** thinks **my** computer is having trouble with the internet or not?

I've tried to find the root cause of this and have come up dry. I'm guessing, either the browser (Chrome) is notifying the web apps, or they are polling constantly to detect outages lasting 1-2 seconds.

MacOS 11/12 on Macbook Air/Pro on a home WIFI of Time Capsule. Two wifi networks, same ESSID, one of them 5GHz. My wife, working on Microsoft Windows has no complaints. Neither does my phone (iOS, Safari).

I'd love to know if

* there is something in my browser I can disable
* there is some pattern in adblock etc. that I can add

Answer: 
#### FOR Loops

* a FOR loop gets the list of directories from your text file
* **Note:** prepare your text file **without quotes** around the directories
* another FOR loop finds all the files in the supplied directories
* uses `usebackq` ([documentation](https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/for)) to deal with spaces in filenames (e.g. "Tom VPKs").
* See SO "[How do you loop through each line in a text file using a windows batch file?](https://stackoverflow.com/q/155932/)"

```
@echo off

set "dTarget=C:\tmp"
set "dSource=C:\Path\to\a text\file.txt"
set "fType=.eps"

rem loop once for each directory in %dSource%
for /F "usebackq tokens=*" %%D in ("%dSource%") do (

  rem loop once for each file in %%D and its subdirectories
  for /F "tokens=* delims= " %%F in ('Dir "%%D" /A:-D /b /s') do (

    rem copy only if %%F's extension matches %fType%
    if  "%%~xF" == "%fType%" (

      copy /V "%%F" "%dTarget%\"  2>nul

    )

  )

)

```
If **PowerShell** is an option, this code wild combine an array of source paths with an array of extensions and then perform the copy operation for all resulting paths:

```
$Target = 'C:\tmp'
$Source = @('M:\z Grafikdesign\articles\44329'
    'M:\z Grafikdesign\articles\24850'
    'M:\z Grafikdesign\articles\26513'
    'M:\z Grafikdesign\articles\27256'
    'M:\z Grafikdesign\articles\29312'
    'M:\z Grafikdesign\articles\30902'
    'M:\z Grafikdesign\articles\41285'
    'M:\z Grafikdesign\articles\42242'
    'M:\z Grafikdesign\articles\42790'
    'M:\z Grafikdesign\articles\43665'
    'M:\z Grafikdesign\articles\43931'
    'M:\z Grafikdesign\articles\44251.2'
)
$Types = @('.txt', '.log', '.bat')

# Create [String[]] of paths with wildcard basename

$Paths = ForEach ($Type in $Types)
{
    Join-Path $Source ('*' + $Type)
} | Sort

# $Paths

Copy-Item $Paths $Target

```