The recorder will evaluate HttpScriptingRules with Action NoHtml or ForceHtml whenever it needs a decision if a HTTP response body is HTML or not. In the absence of such rules or if no such rules return true, the recorder inspects the content-type header of the HTTP response.
This rule type is useful to suppress or force the scripting of a page-level function in cases where the default recording result is not satisfactory.
Often a "404 Not Found" response comes back with an HTML error description, which will cause the scripting of a WebPageUrl or WebPageLink, even when a WebPageAddUrl would be more appropriate.
<HttpScriptingRule> <Name>No HTML for zip files</Name> <Active>true</Active> <Action>NoHtml</Action> <Conditions> <CompareData> <ApplyTo>Http.Initial.Request.Url.Ext</ApplyTo> <Data>zip</Data> </CompareData> </Conditions> </HttpScriptingRule>