Apocrypha IGB Documentation
From EVEDev
| In Game Browser Documentation - Category Home - Documentation Home |
The ingame web browser is a simple but effective HTML-like method for creating interfaces accessible within the game to applications.
Web browser is somewhat overstating things in regards to modern browsers such as Firefox and Opera- the IGB is a limited tool and thus should not be expected to behave like a real web browser. According to CCP, it supports HTML 3.2 and some parts of HTML 4.0.[1] The user agent header the IGB currently use is "EVE-minibrowser/3.0".
The documentation for the IGB is still fairly sketchy- although documentation from CCP exists it is somewhat out of date, hence this recent documentation effort. As such, please do not copy function references or tutorials from CCP documentation- this documentation should only cover proven, workable and tested solutions in the current (Trinity) EVE client.
Contents |
[edit] Page Design
Sections covering design of IGB-compliant pages, best practices, and the language the IGB understands.
[edit] Forms
Which form components are supported and with what limitations
here is what I(qdel3) know
| Tag | Supported parameters | Limitations |
|---|---|---|
| <input> | type
value name | type cannot be 'Button'
and as far as I know you cant set size on text fields also there is no support for the enabled parameter so you cant make a text field or button disabled for editing or clicking |
[edit] CSS
Special Note: The IGB does not recognize "em" widths, they are all silently ignored.
Red fields are Completely Unsupported
White fields are Fully Supported (with the limitation of no "em" values)
Yellow fields have reduced capabilities.
Grey fields need additional testing.
| Style | Known Supported Values | Known Unsupported Values | Notes |
|---|---|---|---|
| background | IGB colors (see below) | url() to image | |
| border |
|
| All borders are rendered as solid on all four sides. |
| bottom | Any value | The bottom and top styles are silently ignored. | |
| color | HEX Values |
| Only #xxx and #xxxxxx color codes are supported. |
| float | All values | The float style causes pages to never finish loading. | |
| font-family | Any value | The font-family style is silently ignored. | |
| font-size | Any px value | ||
| left | Any px value | Any % value |
|
| line-height | |||
| margin | Any px or % value | Percent (%) values on divs are only used for left and right margin size, the top and bottom margins are ignored. | |
| padding | Any px value | Any % value | Using percentage padding seems to cause a problem and prevent page loading. |
| position |
| The IGB treats relative positioning the same as absolute positioning for where to place content after the element. However it does not treat them the same for the left, right, top, bottom tags. | |
| right | Any px value | Any % value |
|
| text-align | |||
| top | Any value | The bottom and top styles are silently ignored. | |
| vertical-align | Any value | Always appears as if vertical-align:top was set, default for most browsers is vertical-align:middle | |
| width | Any px or % value | Anything with a div | Divs are always rendered as though no width were specified |
[edit] HTML
Red fields are Completely Unsupported.
White fields work, for the most part.
| Tag/Field | Known Supported Values | Known Unsupported Values | Notes |
|---|---|---|---|
| a | Any real link | See Below for special links. | |
| alt | Anything | This is the only supported field for tooltips | |
| div | N/A | N/A | Divs are limited in their css support. No floating is allowed and widths are always ignored. Divs inside of tables do work. |
| iframe | N/A | N/A | IFrames are unsupported. The IGB will render what is between the tags, not the linked page. |
| span | Most things | Nesting | When nesting spans all inner spans are silently ignored. |
| table | N/A | N/A | Tables and all tags that go along with them seem to work. |
| title | Anything | The title field is ignored. Use the alt field for tooltips. |
[edit] Special Links
Sections covering links to display systems, routes and regions/constellations in the ingame map browser, or type/player information when clicked.
[edit] Images
- alliancelogo
- Displays the logo of the specified alliance
- Format: <img src="alliancelogo:{allianceID}" size="{size}" />
- Example: <img src="alliancelogo:741602706" size="100" />
- corplogo
- Displays the logo of the specified corporation
- Format: <img src="corplogo:{corporationID}" size="{size}" />
- Example: <img src="corplogo:537992829" size="100" />
- factionlogo
- Displays the logo of the specified faction
- Format: <img src="factionlogo:{factionID}" size="{size}" />
- Example: <img src="factionlogo:500005" size="100" />
- portrait
- Displays the portrait of a character
- Format: <img src="portrait:{characterID}" size="{size}" />
- Example: <img src="portrait:1558316328" size="100" />
- Note: These are rendered on the spot and thus can be set to any size with no quality loss.
- starmap
- Displays a starmap based on constellations with optional markers
- Format: <img src="starmap:ids={constellationID(s)}&markers={list of markers}" size="{size}">
- Examples
- Fislipesnes:<img src="starmap:ids=20000554&markers=30003794::Stacmon is Here::-::-" size="100" />
- Fislipesnes with Anwyns<img src="starmap:ids=20000554,20000776&markers=30003794::Stacmon::-::-,30005307::Aidart::-::-" size="200" />
- Notes:
- The constellationIDs are comma separated as are the marker lists
- All marker lists are of the format {solarsystemID}::{Tag}::-::-
- typeicon
- Displays the icon for the specified item
- Format: <img src="typeicon:{typeID}" size="{size}" />
- Example: <img src="typeicon:647" size="100" />
[edit] Links
- Solar System Information
- Shows information on a specific solar system
- Format: <a href="showinfo:5//{SYSTEM_ID}">Solar System</a>
- Example: <a href="showinfo:5//30003280}">6-CZ49</a>
- Corporation Information
- Shows information on a specific solar system
- Format: <a href="showinfo:2//{CORP_ID}">Corp Name</a>
- Example: <a href="showinfo:2//213725304}">Etoilles Mortant Ltd.</a>
- Player Information
- Shows information on a player
- Format: <a href="showinfo:{TYPE_ID}//{PILOT_ID}">Pilot Name</a>
- Remark: since you usually dont know the specific typeid (eg the previously stated '1377' is 'CharacterGallente') you should use '1' as typeid which is the group 'Character'
- Example: <a href="showinfo:1//1955457350">Firesh</a>
- Fleet Invitation
- Invites a pilot into an existing fleet
- Format: <a href="gang:{fleetID}">Fleet Invitation</a>
- Example: <a href=gang:1119910354775>Fleet Invitation (Alliance)</a>
[edit] Authentication and Trust
The IGB supports a rudimentary trust mechanism to prevent rogue IGB websites harvesting potentially sensitive data from the character viewing the page.
DO NOT RELY ON THE SECURITY OF THIS MECHANISM FOR AUTHENTICATING USERS!!
The IGB headers can be faked very easily- if you validate corporation/alliance data via the IGB your site is insecure and should use the API keys instead.
[edit] Trust Implementations
Various language implementations of Trust mechanisms.
[edit] Automatic Refreshing
The IGB can be told to refresh via three methods. The simplest and least powerful is the old "meta refresh" HTML tag within the header of the document. The IGB seems to place restrictions on exactly what is allowed here; for example it appears to fail to honor actual refresh requests if a full URL is specified, and occasionally when GET parameters are specified.
If at all possible it is much more reliable to have your web server send a refresh header, which is what the meta refresh is a poor imitation of. The IGB supports two methods of refreshing via the refresh header, and both can be used simultaneously. The first method is the simple timed refresh, for example:
<?php header('Refresh: 10;URL=http://'.$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']); ?>
This will cause the page to automatically refresh every 10 seconds.
The second method is to use the special eve IGB interval called sessionchange which will cause a reload only when the user changes sessions in game; changing systems, docking, and undocking are session changes. This is accomplished by simply substituting the timeout time above with the word 'sessionchange'.
<?php header('Refresh: sessionchange;URL=http://'.$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']); ?>
These two methods can be combined simultaneously to periodically refresh the IGB when the user is in a system, and instantly refresh it when they switch to another system, dock, or undock, to provide timely information.
Note that if you are using "trusted mode", it is not uncommon for session changes to submit invalid data from the IGB; most often I have seen the IGB submit HTTP_EVE_STATIONNAME and HTTP_EVE_NEARESTLOCATION both set to 'None' when using the sessionchange refresh. It may be prudent to check for this situation and if it is detected, issue a timed refresh on a short interval, to acquire valid data.
This code will cause the IGB to refresh on a session change when one occurs, or every five minutes otherwise.
<?php header('Refresh: 300;URL=http://'.$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']); header('Refresh: sessionchange;URL=http://'.$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']); ?>
[edit] Headers
Once IGB trusts your site, it includes several HTTP headers that indicate the location and identity of the pilot. All of the data is supplied by the client and trivial to forge so none of it should be trusted unless other means of verification have been established.
| Name | PHP Code | Example Value | Notes |
|---|---|---|---|
| General | |||
| Eve.Trusted | $_SERVER['HTTP_EVE_TRUSTED'] | yes | If this is not equal to "yes", then none of the other headers will be present. |
| Eve.Serverip | $_SERVER['HTTP_EVE_SERVERIP'] | 87.237.38.200:26000 | This will tell you if the pilot is on tranquility, multiplicity, or singularity. |
| Character | |||
| Eve.Charname | $_SERVER['HTTP_EVE_CHARNAME'] | WoogyDude | That's the character's name. |
| Eve.Charid | $_SERVER['HTTP_EVE_CHARID'] | 1164427832 | That's the character's ID. |
| Eve.Regionname | $_SERVER['HTTP_EVE_REGIONNAME'] | Delve | Shows what region the character is currently in. |
| Unknown | When in a wormhole system. | ||
| Eve.Constellationname | $_SERVER['HTTP_EVE_CONSTELLATIONNAME'] | W-4U1E | Shows what constellation the character is currently in. |
| Unknown | When in a wormhole system. | ||
| Eve.Solarsystemname | $_SERVER['HTTP_EVE_SOLARSYSTEMNAME'] | QY6-RK | Shows what solarsystem the character is currently in. |
| J205738 | When in a wormhole. | ||
| Eve.Nearestlocation | $_SERVER['HTTP_EVE_NEARESTLOCATION'] | QY6-RK VI - Moon 24 | When the nearest celestial object is a moon. |
| QY6-RK IV - Asteroid Belt 1 | When the nearest celestial object is an asteroid belt. | ||
| QY6-RK IV | When the nearest celestial object is a planet. | ||
| Stargate (J-LPX7) | When the nearest celestial object is a stargate. | ||
| Uncharted Planet IV - Moon 9 | When near a moon in a wormhole system. | ||
| None | When the pilot is docked. | ||
| Eve.Stationname | $_SERVER['HTTP_EVE_STATIONNAME'] | None | When the pilot is not docked. |
| Tash-Murkon Prime V - Moon 1 - Tash-Murkon Family Bureau | When the pilot is docked. | ||
| Corporation | |||
| Eve.Corpname | $_SERVER['HTTP_EVE_CORPNAME'] | GoonFleet | Name of the character's Corporation. |
| Eve.Corpid | $_SERVER['HTTP_EVE_CORPID'] | 749147334 | ID of the character's Corporation. |
| Eve.Corprole | $_SERVER['HTTP_EVE_CORPROLE'] | 2199024312320 | Binary number reveals roles, shows "0" if no roles. |
| Alliance | |||
| Eve.Alliancename | $_SERVER['HTTP_EVE_ALLIANCENAME'] | GoonSwarm | Not sent if the character's corporation is not in an alliance. |
| Eve.Allianceid | $_SERVER['HTTP_EVE_ALLIANCEID'] | 824518128 | Shows "None" if character's corporation is not in an alliance. |
ASP.NET - C#
You can also use the above headers with ASP.NET by using the following request, but you must remove the EVE_ prefix
string allianceName = Request.Headers["EVE_ALLIANCENAME"]; long corpRole = Convert.ToInt64(httpRequest.Headers["EVE_CORPROLE"]);

