NoThanks
 _   _     _____ _                 _        
| \ | |   |_   _| |               | |       
|  \| | ___ | | | |__   __ _ _ __ | | _____ 
| . ` |/ _ \| | | '_ \ / _` | '_ \| |/ / __|
| |\  | (_) | | | | | | (_| | | | |   <\__ \
\_| \_/\___/\_/ |_| |_|\__,_|_| |_|_|\_\___/

Put control in the hands of the user.  NoThanks is configured using a
killfile which is typically located in the Muffin preferences
directory.  This killfile supports a small control language comprised
of the "strip", "kill", "redirect", "content", "replace", and "tagattr"
commands.  "#include filename" is also supported.

Commands:

* strip tag [endtag]

  Remove tag and possibly everything up-to and including its end tag.
  Examples:

  Remove the bgsound tag:

      strip bgsound

  Remove the marquee tag and all its contents:

      strip marquee /marquee

  Remove the blink start tag but not its contents:

      strip blink

  Remove the end blink tag.

      strip /blink

* kill regex

  Remove tags end their contents that refer to URLs that match
  the regular expression.  All kill entries are merged into
  one expression.  Requests that match killed URLs are denied.
  Examples:

  Don't access anything from doubleclick.net or linkexchange.net:

      kill doubleclick.net
      kill linkexchange.net

  Don't access URLs that contains these:

      kill AdID=
      kill SpaceID=
      kill sponsor
      kill D=yahoo
      kill /advertise

  Kill /ad/, /adv/, and /ads/ in any case:

      kill /[Aa][Dd]/
      kill /[Aa][Dd][Vv]/
      kill /[Aa][Dd][Ss]/

* redirect regex URL

  Any requested URL that matches regular expression is instead
  sent to the specified URL.
  Example:

  Send any playboy requests to the whitehouse:

      redirect playboy http://www.whitehouse.gov/

* content regex

  Any requested content-type that matches the regular expression
  is rejected.

* replace some-tag another-tag

  Replace a tag with another tag.
  Examples:

  Replace <tr> with <br>

      replace tr br

  Replace <hr> with <hr border=5 noshade>

      replace hr "hr border=5 noshade"

* tagattr tag.attr command [regex] [args ...]

  Operate on tag attributes.
  Supported commands:

      * strip [regex] - Strip tag if regex matches attribute value.

      * remove [regex] - Remove attribute if regex matches attribute value.

      * replace [regex] new-value - Replace attribute if regex matches attribute value.

  The regex ".*" (match everything) is used when a regex is not supplied.

  Examples:

  Remove <a> if it contains the onmouseover attribute

      tagattr a.onmouseover strip

  Remove <applet> if code attribute matches MakeMoneyFast.class

      tagattr applet.code strip MakeMoneyFast.class

  Remove bgcolor attribute from <body>

      tagattr body.bgcolor remove

  Remove href from <a> if the URL matches doubleclick.net

      tagattr a.href remove doubleclick.net

  Replace all <img> src values

      tagattr img.src replace http://mysite/image.jpg

  Replace <img> src value if it contains /sponsors

      tagattr img.src replace /sponsors http://mysite/image.jpg

Complete example:

strip bgsound
strip marquee /marquee
strip blink
strip /blink
kill doubleclick.net
kill linkexchange.com
kill AdID=
kill SpaceID=
kill sponsor
kill D=yahoo
kill gtplacer
kill /[Aa][Dd]/
kill /[Aa][Dd][Vv]/
kill /[Aa][Dd][Ss]/
kill /advertise
kill try-it
redirect playboy http://www.whitehouse.gov/
redirect microsoft http://www.yahoo.com/
tagattr a.onmouseover strip
tagattr applet.code strip MakeMoneyFast.class
tagattr body.bgcolor remove
tagattr a.href remove adserver.com
tagattr img.src replace /adserver http://mysite/image.jpg

Preferences:

* NoThanks.killfile

  Location of NoThanks killfile.


See the README.regex file for information on the supported
regular expression syntax.
