Palview4 Manual * The Palview Pages * The Palview Developers Forum * Home * Palamede

## The Index Something completely new to Palview4 is its ability to generate both a game index and an opening index. This can be an especially useful new tool for site-based magazines that maintain a large number of games. The index is compatible with the new magazine game viewer and automatically links to the games themselves for replay. To create an index, you simply insert the appropriate command into your magazine page. To insert a game index you would use:
    <!-- palview gameindex -->
To insert an opening index you would use:
    <!-- palview openindex -->
The index will be inserted into the magazine page at the place of the insertion command itself. Only those games that are inserted into the magazine will be included in the index. Other games may appear in the PGN file that are not used in the magazine, but these games will not be included in your index. Also note that the entire magazine's template file will be read twice, so that the first time it is read all the games to be inserted will be known and collected for both indices. You don't have to place the index at the end of the magazine in order to get all the games included. It is also possible to insert static games into your magazine, but these games will not be indexed since they have no replayable counterpart. Only replayable games are indexed — not static games. Palview always writes an anchor before the indices themselves that can be used as a target for a link, say from a Table of Contents. This anchor always contains the name of the index itself as in this example:
    ...
    <A NAME='pgameindex'></A>
    ... game index here

    <A NAME='popenindex'></A>
    ... opening index here
## The Game Index The game index lists all the game's players from A to Z. (Player's whose names begin with a letter other than A to Z are placed in a special index entry called Other.) The pattern of the player's names in the index is controlled by the new INI option indexnamepattern. The following game index example uses indexnamepattern = last, which is the default. The tooltipindex command can be used to include extended information in the indices about each game in a tooltip that appears when you hover over the game's number. This can been seen in the above game index example. Notice in the above game tooltip example that the extended information includes: ECO, game result, the number of moves in the game (N), and the name of the Event. If Round information is provided in a game, it will be shown in the tooltip as rN just before the name of the Event. Another important feature to note about the game index, is that some of the game number links are bold whereas others are not. A bold game number indicates that the player named in the index entry (using all uppercase letters) played the white pieces in the game, otherwise the player was black. In the above example, the index entry BOGDAN - Jung 8 indicates that Bogdan played white in the game, whereas the entry BROWN - Harris 22 indicates that Brown played the black pieces in that game. The game index CSS is covered in detail in the section, CSS for the Index. The actual CSS classes themselves must be in the CSS file used by the magazine page. This CSS file is set with the new INI option magazinecss. ## The Opening Index The opening index lists all the game's openings starting from the ECO code. ECO codes are listed from book A to E and from numbers 00 to 99. Following the ECO code is the actual name of the game's Opening as defined in the ecofilename. For the opening index, it is very important to note that you must be using an ecofilename in order to allow Palview to determine the actual openings of the games. (For more details about the ecofilename, please see the section The P3eco Program and Opening Names.) Notice in the above opening index tooltip example that the extended information includes: White - Black, game result, the number of moves in the game (N), and the name of the Event. If Round information is provided in a game, it will be shown in the tooltip as rN just before the name of the Event. This extended information is provided when you set the tooltipindex INI option to on. The opening index CSS is covered in detail in the section, CSS for the Index. The actual CSS classes themselves must be in the CSS file used by the magazine page. This CSS file is set with the new INI option magazinecss.