I try to make an expression that will search on the page, for example how2bypass.co.cc, and return the contents of the action attribute in the "form" tag, and the contents of the "name" and "type" in any input tags. I cannot use the html parser because my ultimate goal is to automatically determine if a given page is a web proxy, and as soon as the sites catch it, I do this, they will probably start doing stupid things like writing an entire document with javascript to stop me from parsing it.
I am using code
preg_match_all('/<form.*action\="(.*?)".*>[^<]*<input.*type\=/i', $pageContents, $inputMatches);
which is great for the action attribute, but after I put "after type \ = code stops working", why is this? Does it work fine once, but not twice?
source share