1 Mini HOWTO create a "User-Agent" description file for KDE
2 =========================================================
4 This mini HOWTO describes the procedure for creating a new user-agent
5 description file to extend the ones that come pre-packaged with KDE.
6 The purpose of a user agent description file is to fake or spoof sites
7 that refuse to render pages with the default KDE user-agent identification.
9 In order to create new user-agent description files, simply follow the
10 normal desktop file specifications set by the "DESKTOP ENTRY STANDARD"
11 augmented with the following requirements:
15 The following properties as defined by the DESKTOP ENTRY STANDARD
16 must be set as shown below:
18 Name=UADescription (XXXX)
20 ServiceTypes=UserAgentStrings
22 Though the (XXXX) value shown above can be any text, it is a good idea
23 to make it a short identification of the browser being emulated. However,
24 there is NO requirement on what the text should be. It can even be left
25 out. It is only meant to give people a quick idea which browser is being
26 emulated by your desktop file.
35 An abbreviation of the actual browser-brand and is used
36 to group the entries whenever necessary. Currently there are 5
37 approximations: IE, NN, MOZ, OP, MISC. These represent Internet
38 Explorer, Netscape Navigator, Mozilla, Opera and Miscellaneous
39 respectively. NOTE: you can enter any value here as it is just
40 a place holder that would be automatically replaced with the
41 actual user-agent name (X-KDE-UA-NAME).
48 The full user-agent description that will be sent to the remote
49 site. It can contain the following keywords that would be replaced
50 with the appropriate value as defined by "uname":
52 appSysName the name of the operating system (ex: Linux).
53 appPlatform the name of the platform. Currently hardcoded to "X11".
54 appLanguage the language values as set in the control panel (ex: en, en-US).
55 appSysRelease the version of the operating system (ex: 2.2.18).
56 appKDERelease the current release number as set by KDE (ex: 2.1.9 >=20010310).
57 appMachineType the processor or machine type (ex: i686).
59 NOTE: if you use any of these values and want them to be replaced
60 automatically, make sure you include the X-KDE-UA-DYNAMIC-ENTRY field
61 and set its value to 1 (for true).
68 The actual name of the browser or user-agent.
75 The actual version of the browser or user-agent.
82 The system name (for example Linux) where the browser
83 identification was obtained from.
90 The system version (for example 2.4.1) where the browser
91 identification was obtained from.
93 X-KDE-UA-DYNAMIC-ENTRY
98 A boolean that indicates whether the keywords described under
99 X-KDE-UA-FULL should be translated. Make sure this field is
100 there with its value set to "1" if you want the keywords to
101 be replaced appropriately.
107 Name=UADescription (IE 5.5 on Win 98)
109 ServiceTypes=UserAgentStrings
111 X-KDE-UA-FULL=Mozilla/4.0 (compatible; MSIE 5.5; Windows 98)
112 X-KDE-UA-NAME=Internet Explorer
114 X-KDE-UA-SYSNAME=Windows
115 X-KDE-UA-SYSRELEASE=98
118 Name=UADescription (NN 4.76 on current)
120 ServiceTypes=UserAgentStrings
122 X-KDE-UA-FULL=Mozilla/4.76 (appPlatform; U; appSysName appSysRelease appMachineType)
123 X-KDE-UA-NAME=Netscape Navigator
124 X-KDE-UA-VERSION=4.76
125 X-KDE-UA-DYNAMIC-ENTRY=1
127 The first entry is a description file for Internet Explorer running on
128 a Windows 98 machine while the second one is an example of a description
129 file for Netscape browser using the "keyword" based approach to describe
130 the fields that should be replaced dynamically based on the current system
131 settings. Note that all "keyword" based desktop files should always set
132 X-KDE-UA-DYNAMIC-ENTRY to 1.