# $Id: supports,v 1.92 2005/10/21 09:31:05 jonasw Exp $

# --- Supports database ---
# The database used to determine what different user-agents (browsers) support.


# Documentation

#! The file syntax is quite straightforward:
#! regular_expression  value,value,value...
#! -value can be used to remove a value
#! \ can be used to escape newlines.
#! Values in the *key=value form will have its value
#! copied to the variable named key in the client namespace.
#!
#! If a line starts with '#', it is skipped, unless it is
#!
#! '#include <file>'
#! (include the file 'file' here)
#!
#! '#define <from> <to>'
#! (replace all 'from' with 'to' below this point in the file)
#!
#!  or
#!
#! '#section name {'
#! '# }'
#!
#! (The section stuff is used to speed up the matching of the
#!  clientname from the patterns, the 'name' _must_ be first in the
#!  clientname for the patterns in the 'section' to be checked).
#!
#! Supports Flags
#!
# <flags>
#! activex - The browser handles activeX contents.
#! align - The browser supports the align attribute in its tags.
#! autogunzip - The browser can decode a gzipped file on the fly.
#! backgrounds - The browser supports backgrounds according to the HTML3 specifications.
#! bigsmall - The browser supports the <big> and <small> tags.
#! center - The browser supports the <center> tag.
#! cookies - The browser can receive cookies.
#! divisions - The browser supports <div> tags.
#! div - Same as divisions.
#! font - The browser supports the font tag.
#! fontcolor - The browser can change color of individual characters.
#! forms - The browser supports forms according to the HTML 2.0 and 3.0 specifications.
#! frames - The browser supports frames.
#! gifinline - The browser can show GIF images inlined.
#! html - This is a HTML browser (as opposed to e.g. a WAP browser).
#! imagealign - The browser supports align=left and align=right in images.
#! images - The browser can display images.
#! java - The browser supports Java applets.
#! javascript - The browser supports javascripts.
#! jpeginline - The browser can show JPEG images inlined.
#! js_global_event - The browser supports a global event object e.g. netscape 4.
#! js_image_object - The browser supports the javascript image object.
#! js_inner_html - The browser supports the javascript propperty innerHTML.
#! layer - The browser supports the layer tag.
#! mailto - The browser supports mailto URLs.
#! math - The <math> tag is correctly displayed by the browser.
#! msie - This is a Microsoft Internet Explorer browser.
#! noscript - The browser honours the <noscript> tag (by showing its contents only when javascript is not on).
#! phone - The client is a phone.
#! pjpeginline - The browser can handle progressive JPEG images, .pjpeg, inline.
#! pnginline - The browser can handle PNG images inlined.
#! pull - The browser handles Client Pull.
#! push - The browser handles Server Push.
#! robot - The request really comes from a web robot, not an actual browser.
#! ssl - The browser handles secure sockets layer.
#! stylesheets - The browser supports stylesheets.
#! supsub - The browser handles <sup> and <sub> tags correctly.
#! tables - The browser handles tables according to the HTML3.0 specification.
#! tablecolor - It is possible to set the background color in the browser.
#! tableimages - It is possible to set a backgroud image in a table in the browser.
#! trade - The browser supports the &trade; entity.
#! unknown - The browser is not known, hence the supports classes can not be trusted.
#! vrml - The browser supports VRML.
# Keep the flags wbmp0, wml1.0 and wml1.1 for compatibility.
#! wbmp - The browser supports Wireless Bitmap Picture Format.
#! wml - The browser supports Wireless Markup Language 1.1.
# </flags>
#!
#! Supports variables
#!
# <vars>
#! height - The presentation area height in pixels.
#! javascript - The highest version of javascript supported.
#! robot - The name of the web robot.
#! width - The presentation area width in pixels.
# </vars>

#define basic		images, forms, gifinline, mailto, html, noscript
#define some_html3	divisions, div, supsub, bigsmall, align


## Netscape is named "mozilla/major.minor system ..."

#section mozilla {

.*		basic, tables, jpeginline, font, imagealign,\
		cookies, push, pull, backgrounds, ssl,\
		java, frames, autogunzip, js_image_object, javascript,\
		align, center, images

^mozilla/0\..*		-tables, -backgrounds, -ssl, -frames, -java, -javascript,\
			-js_image_object, -align, -center, -font, -imagealign,\
			-images
^mozilla/1.[01].*	-tables, -backgrounds, -ssl, -frames, -java, -javascript,\
			-js_image_object
^mozilla/1\..*		-ssl, -frames, -java, -javascript, -js_image_object,\
			bigsmall, supsub
^mozilla.[2-9].[0-9].*	some_html3, fontcolor, pjpeginline, fontcolor
^mozilla.2.0b[2-9].*	-java

#Old versions on Mac crash the entire machine if you use javascript.
^mozilla/2.*		-js_image_object, -noscript, *javascript=1.0
^mozilla/2.*X11		javascript
^mozilla/2.*OS/2	javascript
^mozilla/2.*Win16	-java, javascript
^mozilla/2.*Macintosh	-java

^mozilla/[2-9].*	js_global_event
^mozilla/[3-9].*	javascript, tablecolor, *javascript=1.1

^mozilla/[4-9].*	stylesheets, tableimages, *javascript=1.1
^mozilla/[4].*		layer
^mozilla/4\.0[4-9].*	pnginline
^mozilla/4\.0[1-5].*	*javascript=1.2
^mozilla/4\.0[6-9].*	*javascript=1.3
^mozilla/4\.[1-9].*	pnginline, *javascript=1.3
^mozilla/5\.0b1		-java, pnginline
^mozilla/[5-9].*	pnginline, *javascript=1.5, js_inner_html

# Opera

.*compatible.*opera.1.*		-align, -backgrounds, -bigsmall, -center, -div,\
				-divisions, -font, -forms, -frames, -imagealign,\
				-supsub
.*compatible.*opera.2.*		align, fontcolor, tablecolor
.*compatible.*opera.[3-9].*	-java, javascript, fontcolor, tablecolor, *javascript=1.1
.*compatible.*opera.[4-9].*	trade
.*compatible.*opera.[5-9].*	*javascript=1.3, stylesheets


# BLAM BLAM BLAM BLAM
.*compatible.*			-push, -layer, -js_global_event
.*compatible.*msie		msie
.*compatible.*msie.1		-javascript, -tables
.*compatible.*msie.[1-2]	-java, -bigsmall, -div, -divisions, fontcolor,\
				-frames, -supsub
.*compatible.*msie.2		-noscript
.*compatible.*msie.[1-3]	-js_image_object

.*compatible.*msie.[2-9]	tablecolor, fontcolor
.*compatible.*msie.[3-9]	activex, tableimages, javascript, *javascript=1.0
# MSIE3 stylesheets are broken
.*compatible.*msie.[4-9]	stylesheets, trade, *javascript=1.2
.*compatible.*msie.[5-9]	js_inner_html, pnginline
.*compatible.*msie.5\.0		*javascript=1.3
# }

gecko				basic, some_html3, backgrounds, center, cookies,\
				font, fontcolor, forms, frames, gifinline, imagealign,\
				images, javascript, jpeginline, js_global_event,\
				js_image_object, js_inner_html, pjpeginline,\
				pnginline, stylesheets, tables, tablecolor, tableimages,\
				*javascript=1.5

# section opera {
.*		basic, tables, jpeginline, font, imagealign,\
		cookies, push, pull, backgrounds, ssl,\
		java, frames, autogunzip, js_image_object, javascript,\
		align, center, images \
		*javascript=1.5, js_global_event,\
		js_inner_html, pnginline, trade, stylesheets
# }


#section netsurfer {
# Netsurfer is a popular commercial Web browser for NEXTSTEP. for more
# info, contact info@netsurfer.com
.*			basic, jpeginline, center
^netsurfer.1\.[1-9].*	backgrounds, fontcolor, pnginline, videoinline
^netsurfer.2\.[0-9].*	align, pjpeginline, tables, frames, java, font,\
			bigsmall, supsub
# }

#section omniweb {
# OmniWeb is another popular commercial Web browser for NEXTSTEP
# for more info, contact info@omnigroup.com
.*			basic, center, jpeginline
^omniweb.[2-9]\.[0-9].*	backgrounds, font, frames, tables, align, bigsmall,\
			fontcolor, imagealign, pjpeginline, pnginline,\
			supsub, ssl, cookies
# }

#section arena {
# Arena is the free WWW browser from CERN/W3O. It is not all that nice yet,
# but it just might get there in the future, if they get some X-programmers..

.*			some_html3, basic, stylesheets

# }

.*mosaic.*		basic

#section ncsa {
# Old Mosaic is not all that interresting..  Even though NCSA claims
# to have table support, it does in fact not work at all, so, I do not
# add that here.
^ncsa.mosaic.*[2-9].[5-9]*.*	supsub
^ncsa.mosaic.*[2-9].[6-9]*.*	jpeginline
^ncsa.mosaic.*[2-9].[7-9]*.*	pnginline

# Mosaic "The Comet" final beta

.*mosaic.*final.beta.*		tables, jpeginline, backgrounds, mailto
# }

# Spyglass mosaic is distributed together with Oracle 7
# Tested version: "Spyglass_Mosaic/2.11 Spyglass/11"
#section spyglass {
.*	basic, backgrounds, center, font, fontcolor, imagealign,\
	jpeginline, pjpeginline, tables
# }

# Newer versions of lynx can handle tables and frames in a fashion, but
# it is probably better not to add them below.

#section lynx {
.*	forms, html
# }

#section emacs {
# Emacs w3 is quite slow, but a very impressive hack...
.*	basic, jpeginline, fonts, imagealign
# }

# Does not support anything at all, really.
^w3.*linemode.*		html
^cern.*linemode.*	html

#section hotjava {
# HotJava, SUNs little WWW browser with support for java aplets.
.*			basic, java, center
.*/1\.0/j.*1\.1\.[1-9]	frames, pjpeginline, supsub, fontcolor,\
			backgrounds, bigsmall, divisions, div, font,\
			imagealign, jpeginline, tables, tablecolor
# }

#section udiwww {
.*	basic, tables, imagealign, backgrounds, font
# }

#section ibrowse {
# Amiga MUIbrowser
.*			basic, center, pnginline, imageinline,\
			backgrounds, bigsmall, center, divisions,\
			div, font, fontcolor, imagealign, tables,\
			jpeginline, pjpeginline, pnginline

.*1.1.*			frames, pull
.*1.1[2-9].*		ssl
# }

#section amiga-aweb {
# Amigabrowser <http://www.xs4all.nl/~yrozijn/aweb/>
.*			basic, center, pnginline, imageinline,\
			backgrounds, bigsmall, center, divisions,\
			div, font, fontcolor, imagealign, supsub,\
			jpeginline, pjpeginline, pnginline

.*1\.[5-9].*		tables
.*[2-9]\.[0-9].*	tables
.*[3-9]\.[0-9].*	cookies, frames, pull, push
# }

# A couple more for IBM's Webexplorer (OS/2) Contributed by Jason
#  Rumney <jasonr@pec.co.nz>
# section ibm {
.*webexplorer.*			basic, jpeginline, font, center
.*webexplorer.*1\.0[3-9]	tables, backgrounds, imagealign
.*webexplorer.*1.1		tables, backgrounds, imagealign
.*webexplorer.*9603.*beta	java, javascript, livescript, tables,\
				backgrounds, imagealign
# }

#section micr {
# Micro$oft Browser.  I have only tested this on an exhibition
# (ComNET '95/Sweden), so this is probably _very_ incomplete by now.
#								/Per
.*exp.*		basic, msie, font, center, imagealign, frames, activex
# }

#section microsoft {
.*url.*control		robot, *robot=ms-url-control
# }

#section chimera {
# Chimera.
.*	basic, -mailto
# }

#
#  --------- WAP ---------
#

#section nokia {
^nokia7110.*	phone, wml1.1, wbmp0, wml, wbmp
^nokia.7110.*	wml1.1, wbmp0, wml, wbmp
.*		wml1.1, wbmp0, wml, wbmp
# }

#section wapide-sdk {
.*		wml1.1, wbmp0, wml, wbmp
# }

#section up.browser {
.*		wml1.1, wbmp0, wml, wbmp
.*si25.*	phone, wml1.0, wbmp0, -wml1.1, *width=90, *height=33
# }

#section mc218 {
.*		wml1.1, wml, gifinline
# }

#section jigsaw {
.*		wml1.1, wbmp0, wml, wbmp
# }

#
#  --------- ROBOTS ----------
#

# How nice it would have been if all robots had 'robot' in their name..

#section architext {
.*		html, robot, *robot=architex
# }

#section backrub {
.*		html, robot, *robot=backrub
# }

#section checkbot {
.*		html, robot, *robot=checkbot
# }

#section fast-webcrawler {
.*		html, robot, *robot=fast
# }

#section freecrawl {
.*		html, robot, *robot=freecrawl
# }

#section freeseek {
.*		html, robot, *robot=passagen
# }

#section gcreep {
.*		html, robot, *robot=gcreep
# }

#section getright {
.*		html, robot, *robot=getright
# }

#section googlebot {
.*		html, robot, *robot=googlebot
# }

#section harvest {
.*		html, robot, *robot=harvest
# }

#section ia_archiver {
.*		html, robot, *robot=alexa
# }

#section infoseek {
.*		html, robot, *robot=infoseek
# }

#section intraseek {
.*		html, robot, *robot=intraseek
# }

#section roxencrawler {
.*		html, robot, *robot=RoxenCrawler
# }

#section lycos {
.*		html, robot, *robot=lycos
# }

#section momspider {
.*		html, robot, *robot=webinfo
# }

#section roxen {
.*		html, robot, *robot=roxen
# }

#section scooter {
.*		html, robot, *robot=altavista
# }

#section scoutget {
.*		html, robot, *robot=scout
# }

#section slurp {
.*		html, robot, *robot=slurp
# }

#section url {
.*minder.*	html, robot, *robot=url-minder
# }

#section webcrawler {
.*		html, robot, *robot=webcrawler
# }

#section wget {
.*		html, robot, *robot=wget
# }

#section xenu {
.*		html, robot, *robot=xenu
# }

#section yahoo {
.*		html, robot, *robot=yahoo
# }

.*robot.*	html, robot, unknown

# Somewhat dubious, but one does probably not write a client in perl,
# unless you have more than 200Mb of memory, so something announcing
# itself as 'libwww-perl' is probably a robot.

.*libwww-perl.*		html, robot, unknown

# Although not a browser I don't think you would call this a robot.
#section w3c_validator {
.*		basic, some_html3, backgrounds, center, fontcolor,\
		forms, imagealign, tables, -robot
# }

#
# --------- Unknown clients ---------
#

# We are just guessing capabilities here...

#section fly {
.*	unknown, basic
# }

#section prodigy-wb {
.*	unknown, basic
# }

#section infolink {
.*	unknown, html, robot
# }

#section gulliver {
.*	unknown, html, robot
}

# The default. If nothing else matches this is used to determine the
# supports values.
default		unknown, tables, center, basic
