in reply to questions of a perl beginner on regex

m/\.swf(?:\?.*)?$/oi
\. # the character '.' swf # the string, 'swf' (?: ... ) # don't save this expression \? # the character '?' .* # zero or more characters (not a newline) ? # zero or one occurances (of the grouping in parens) $ # end of the line /oi # don't re-evaluate, case insensitive.

So, as best I can tell, you're not only grabbing URLs that end in SWF, you're also grabbing URLs that are passing a query string (ie, URL?QUERY_STRING format)