![]() |
adzapper Home | About Adzapper | Installing | Zaplets | Zaplet File Format | Zaplet Updates | ![]() |
This document specifies the zaplet file format using an XML v1.0 DTD.
<!ELEMENT zaplet (version, host, (enabled | modified | repository | comment)*, (block_url | allow_url | block_popups | filter)* )> <!ELEMENT version (#PCDATA)> <!ELEMENT host (#PCDATA)> <!ELEMENT enabled (#PCDATA)> <!ELEMENT modified (#PCDATA)> <!ELEMENT repository (#PCDATA)> <!ELEMENT comment (#PCDATA)> <!ELEMENT filter (filter_match_url, filter_match_text, filter_replace_text)> <!-- type is either "regex", "literal", or "everything" --> <!ELEMENT allow_url (#PCDATA)> <!ATTLIST allow_url type CDATA #REQUIRED> <!ELEMENT block_url (#PCDATA)> <!ATTLIST block_url type CDATA #REQUIRED> <!ELEMENT block_popups (#PCDATA)> <!ATTLIST block_popups type CDATA #REQUIRED> <!ELEMENT filter (filter_match_url, filter_match_text, filter_replace_text> <!ELEMENT filter_match_url (#PCDATA)> <!ATTLIST filter_match_url type CDATA #REQUIRED> <!ELEMENT filter_match_text (#PCDATA)> <!ATTLIST filter_match_text type CDATA #REQUIRED> <!ELEMENT filter_replace_text (#PCDATA)>
When 'type' is 'regex', the contents of the tag are interpreted as a Perl-style regular expression, as specified by the Python re module documentation. For more information, see http://www.python.org/doc/current/lib/module-re.html
The tag 'comment' can contain a comment; it is ignored by adzapper.
The tags 'enabled', 'modified', and 'repository' are reserved for future use.
'block_url' specifies a range of URLs to block- a predefined piece of content, usually a transparent GIF, is returned instead. The entire URL is used as a target for the regular expression or literal to determine matching.
'allow_url' specifies a range of URLs to allow, even if they would otherwise be blocked by block_url statements. As with the 'block_url' statement, the entire URL is used as a target.
'block_popups' specifies a range of URLs to filter out java window.open() calls from. As with 'block_url', the entire URL is used as the target.
'filter_match_url' specifies the range of URLs to apply the filter to, the entire URL is used as the target. 'filter_match_text' specifies the text of an html (or xml or text) page to apply the filter to. 'filter_replace_text' is a literal string that the matching text will be replaced with.
Last Modified: Sun Sep 2 04:50:32 2001