Sports Standings and Rankings Tables
| # | Team | P | W | D | L | GF | GA | GD | Pts | Form |
|---|---|---|---|---|---|---|---|---|---|---|
| 1 | Panathinaikos | 5 | 5 | 0 | 0 | 12 | 2 | +10 | 15 | WWWWW |
| 2 | PAOK | 5 | 4 | 0 | 1 | 12 | 5 | +7 | 12 | WWLWW |
| 3 | AEK | 5 | 3 | 2 | 0 | 13 | 3 | +10 | 11 | WDWDW |
| 4 | OFI | 5 | 3 | 1 | 1 | 8 | 4 | +4 | 10 | WWDWL |
| 5 | Olympiacos | 5 | 3 | 1 | 1 | 4 | 2 | +2 | 10 | WWDWW |
| 6 | Panetolikos | 5 | 3 | 0 | 2 | 8 | 7 | +1 | 9 | WWWLL |
| 7 | Aris | 5 | 2 | 1 | 2 | 5 | 10 | −5 | 7 | WLWDL |
| 8 | Iraklis | 5 | 1 | 3 | 1 | 4 | 6 | −2 | 6 | DWDDL |
| 9 | Kifisia | 5 | 1 | 2 | 2 | 4 | 7 | −3 | 5 | LWDWL |
| 10 | Kalamata | 5 | 1 | 1 | 3 | 6 | 8 | −2 | 4 | DWLLL |
| 11 | Atromitos | 5 | 0 | 2 | 3 | 4 | 7 | −3 | 2 | DLLDL |
| 12 | Asteras Tripolis | 5 | 0 | 2 | 3 | 4 | 9 | −5 | 2 | DDLLL |
| 13 | Volos | 5 | 0 | 2 | 3 | 4 | 9 | −5 | 2 | LLDLD |
| 14 | Levadiakos | 5 | 0 | 1 | 4 | 0 | 9 | −9 | 1 | LDLLL |
| # | Team | P | W | L | PCT | GB | PF | PA | +/- | Home | Away | Form | Strk |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | Detroit Pistons | 82 | 60 | 22 | .732 | — | 9254 | 8872 | +382 | 31-10 | 29-12 | WWLWW | W3 |
| 2 | Boston Celtics | 82 | 56 | 26 | .683 | 4.0 | 9130 | 8764 | +366 | 30-11 | 26-15 | WWWWW | W2 |
| 3 | New York Knicks | 82 | 53 | 29 | .646 | 7.0 | 9042 | 8815 | +227 | 30-10 | 23-19 | WLWWW | L1 |
| 4 | Cleveland Cavaliers | 82 | 52 | 30 | .634 | 8.0 | 8991 | 8840 | +151 | 27-14 | 25-16 | LWWWW | W1 |
| 5 | Toronto Raptors | 82 | 46 | 36 | .561 | 14.0 | 8810 | 8755 | +55 | 24-17 | 22-19 | WWWLW | W1 |
| 6 | Atlanta Hawks | 82 | 46 | 36 | .561 | 14.0 | 8872 | 8833 | +39 | 24-17 | 22-19 | WLWLW | L1 |
| 7 | Philadelphia 76ers | 82 | 45 | 37 | .549 | 15.0 | 8795 | 8740 | +55 | 23-18 | 22-19 | WWLWW | W2 |
| 8 | Orlando Magic | 82 | 45 | 37 | .549 | 15.0 | 8712 | 8680 | +32 | 25-15 | 20-22 | WLWLW | L1 |
| 9 | Charlotte Hornets | 82 | 44 | 38 | .537 | 16.0 | 8660 | 8642 | +18 | 21-20 | 23-18 | LWWLW | W1 |
| 10 | Miami Heat | 82 | 43 | 39 | .524 | 17.0 | 8608 | 8615 | −7 | 26-15 | 17-24 | WLWWW | W2 |
| 11 | Milwaukee Bucks | 82 | 32 | 50 | .390 | 28.0 | 8425 | 8790 | −365 | 19-22 | 13-28 | LLWLL | L1 |
| # | Team | P | W | L | SW | SL | SD | SR | PF | PA | PR | Pts | Form |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | France | 10 | 9 | 1 | 28 | 8 | +20 | 3.500 | 812 | 672 | 1.208 | 27 | WWWWW |
| 2 | Poland | 10 | 8 | 2 | 26 | 10 | +16 | 2.600 | 788 | 690 | 1.142 | 24 | WWLWW |
| 3 | Italy | 10 | 7 | 3 | 24 | 13 | +11 | 1.846 | 760 | 701 | 1.084 | 22 | WLWWW |
| 4 | Brazil | 10 | 6 | 4 | 22 | 16 | +6 | 1.375 | 742 | 715 | 1.038 | 19 | WWLLW |
| 5 | USA | 10 | 6 | 4 | 21 | 17 | +4 | 1.235 | 735 | 720 | 1.021 | 18 | WLWLW |
| 6 | Japan | 10 | 5 | 5 | 19 | 18 | +1 | 1.056 | 711 | 706 | 1.007 | 16 | LWWLW |
| 7 | Slovenia | 10 | 5 | 5 | 18 | 19 | −1 | 0.947 | 700 | 712 | 0.983 | 15 | WLLWW |
| 8 | Serbia | 10 | 4 | 6 | 17 | 21 | −4 | 0.810 | 688 | 735 | 0.936 | 13 | LLWWL |
| 9 | Germany | 10 | 3 | 7 | 14 | 23 | −9 | 0.609 | 655 | 748 | 0.876 | 10 | LWLLL |
| 10 | Netherlands | 10 | 2 | 8 | 11 | 26 | −15 | 0.423 | 620 | 779 | 0.796 | 7 | LLLLW |
| # | Team | P | W | D | L | GF | GA | GD | Pts | Form |
|---|---|---|---|---|---|---|---|---|---|---|
| 1 | Olympiacos | 12 | 11 | 1 | 0 | 352 | 281 | +71 | 23 | WWWWW |
| 2 | AEK Athens | 12 | 10 | 0 | 2 | 340 | 290 | +50 | 20 | WWLWW |
| 3 | PAOK | 12 | 8 | 2 | 2 | 331 | 300 | +31 | 18 | WDWWL |
| 4 | Diomidis Argous | 12 | 7 | 1 | 4 | 318 | 309 | +9 | 15 | WWLDW |
| 5 | Ionikos | 12 | 5 | 3 | 4 | 301 | 299 | +2 | 13 | DWDLW |
| 6 | Drama 1986 | 12 | 5 | 1 | 6 | 297 | 305 | −8 | 11 | LWWLL |
| 7 | Zafeirakis Naousas | 12 | 4 | 1 | 7 | 288 | 312 | −24 | 9 | LDLWL |
| 8 | Kilkis | 12 | 3 | 2 | 7 | 279 | 301 | −22 | 8 | DLLWL |
| 9 | Archelaos Katerinis | 12 | 2 | 1 | 9 | 270 | 322 | −52 | 5 | LLDLL |
| 10 | Aeropos Edessas | 12 | 1 | 0 | 11 | 255 | 346 | −91 | 2 | LLLLL |
| # | Team | P | W | D | L | Pts | Form | Strk |
|---|---|---|---|---|---|---|---|---|
| 1 | Falcons | 10 | 8 | 1 | 1 | 25 | WWDWW | W2 |
| 2 | Tigers | 10 | 7 | 2 | 1 | 23 | WWWDW | W1 |
| 3 | Eagles | 10 | 6 | 2 | 2 | 20 | LWWDW | W1 |
| 4 | Sharks | 10 | 6 | 1 | 3 | 19 | WLWWL | L1 |
| 5 | Wolves | 10 | 5 | 2 | 3 | 17 | DWLWW | W2 |
| 6 | Bears | 10 | 4 | 3 | 3 | 15 | DDWLW | W1 |
| 7 | Hawks | 10 | 3 | 3 | 4 | 12 | LDWDL | L1 |
| 8 | Lions | 10 | 3 | 1 | 6 | 10 | LLWLW | W1 |
| 9 | Panthers | 10 | 2 | 2 | 6 | 8 | LLDLL | L2 |
| 10 | Rhinos | 10 | 1 | 1 | 8 | 4 | LLLDL | L1 |
| # | Team | Pts | Prev | +/- |
|---|---|---|---|---|
| 1 | Poland | 412.4 | 1 | — |
| 2 | Italy | 398.1 | 3 | 1 |
| 3 | France | 392.7 | 2 | 1 |
| 4 | Brazil | 361.9 | 4 | — |
| 5 | Japan | 355.2 | 7 | 2 |
| 6 | USA | 349.8 | 5 | 1 |
| 7 | Slovenia | 338.0 | 6 | 1 |
| 8 | Argentina | 301.5 | 8 | — |
| 9 | Serbia | 297.3 | 11 | 2 |
| 10 | Germany | 290.6 | 9 | 1 |
| 11 | Canada | 284.9 | 10 | 1 |
| 12 | Turkey | 279.4 | 12 | — |
Sports Standings & Rankings Tables
Turn a plain list of results into a polished league table or ranking. Give it the numbers you have — wins, draws, losses, goals — and it works out the rest: matches played, differences, points, winning percentage, games behind, the order of the teams and their movement, with recent form shown as coloured badges.
- The six rulesets
- Quick start
- The header row
- Football (Soccer)
- Basketball
- Volleyball
- Handball
- Generic standings
- Rankings
- Recent form
- Zones: title, qualification, relegation
- Highlighting a team
- Team logos
- Ruleset options
- Languages
- Colours and styling
- Header key reference
The six rulesets
Pick the ruleset for your sport. They share one design; each has its own accent colour.
rs_sportstables_1 · 3 points for a win, 1 for a draw; ordered by points, goal difference, goals scored.rs_sportstables_2 · winning percentage, games behind, point differential.rs_sportstables_3 · set difference, set ratio and point ratio; league points from your data.rs_sportstables_4 · any sport: wins, draws, losses and points.rs_sportstables_5 · 2 points for a win, 1 for a draw; ordered by points, goal difference, goals scored.rs_sportstables_6 · ranking points, previous position and movement arrows.Each ruleset comes with a sample data source, so you can see it working straight after importing.
Quick start
- Prepare your data as a table or CSV file. The first row names what each column holds, using the short keys described below (
team,w,d,l, …). - Apply the ruleset for your sport to it, the same way as any other Tabulizer ruleset.
- That's it: missing values are calculated, and the teams are put in order and ranked.
For example, this is all a football table needs:
team,w,d,l,gf,ga,form
Panathinaikos,5,0,0,12,2,WWWWW
PAOK,4,0,1,12,5,WWLWW
AEK,3,2,0,13,3,WDWDW
and it becomes a table with the columns # · Team · P · W · D · L · GF · GA · GD · Pts · Form — matches played, goal difference, points and the positions are worked out for you.
The header row
The first row is not shown as data. Each of its cells tells the ruleset what that column contains:
- Keys are not case sensitive:
team,TeamandTEAMare the same. Spaces, dashes, dots and underscores are ignored, soGoals Forworks as well asgoals_for. - Common alternative names are understood:
club,country,playerornamefor the team;played,gpormpfor matches played;won,drawn,lost; and so on. The full list is in the reference. - The order of your columns does not matter: the table always shows them in the standard order for the sport.
- You do not need every column. Columns you leave out are simply not shown — unless they can be calculated from the others.
- Columns the ruleset does not recognise are ignored, so your file can hold extra information.
If your data has a rank column, the positions you give are kept, and so is your order. Without it, the teams are ordered and numbered for you. A team tied with another on every criterion stays in the order it had in your data.
Football (Soccer)
| Key | Column | Calculated when missing |
|---|---|---|
rank |
Position | from the order below |
team |
Team | |
p |
Played | w + d + l |
w d l |
Won, drawn, lost | |
gf ga |
Goals for, goals against | |
gd |
Goal difference | gf − ga, shown as +5 / −3 |
pts |
Points | 3 × w + d |
form streak |
Recent results, current streak |
Order: points, then goal difference, then goals scored.
team,w,d,l,gf,ga,form
Panathinaikos,5,0,0,12,2,WWWWW
PAOK,4,0,1,12,5,WWLWW
AEK,3,2,0,13,3,WDWDW
OFI,3,1,1,8,4,WWDWL
win_points=2 in the ruleset options.Basketball
| Key | Column | Calculated when missing |
|---|---|---|
p |
Games played | w + l |
w l |
Wins, losses | |
winpct |
Winning percentage (PCT) | w ÷ p, shown as .732 |
gb |
Games behind the leader | ((leader w − w) + (l − leader l)) ÷ 2; the leader shows — |
pf pa |
Points for, points against | |
diff |
Point differential (+/-) | pf − pa |
conf div |
Conference, division record | |
home away |
Home and away record, e.g. 31-10 |
|
form streak |
Recent results, streak such as W3 |
Order: winning percentage, then wins, then fewer losses, then point differential.
team,w,l,pf,pa,home,away,form,streak
Detroit Pistons,60,22,9254,8872,31-10,29-12,WWLWW,W3
Boston Celtics,56,26,9130,8764,30-11,26-15,WWWWW,W2
New York Knicks,53,29,9042,8815,30-10,23-19,WLWWW,L1
Volleyball
| Key | Column | Calculated when missing |
|---|---|---|
p |
Matches played | w + l |
w l |
Wins, losses | |
sf sa |
Sets won, sets lost | |
sd |
Set difference | sf − sa |
setratio |
Set ratio | sf ÷ sa (none while no set is lost) |
pf pa |
Rally points won and lost | |
point_ratio |
Point ratio | pf ÷ pa |
pts |
League points | not calculated — see below |
Order: points, then wins, then set ratio, then point ratio.
pts column with your competition's points.team,w,l,sf,sa,pf,pa,pts,form
France,9,1,28,8,812,672,27,WWWWW
Poland,8,2,26,10,788,690,24,WWLWW
Italy,7,3,24,13,760,701,22,WLWWW
Handball
The same columns and order as football, with handball's points: 2 for a win, 1 for a draw.
team,w,d,l,gf,ga,form
Olympiacos,11,1,0,352,281,WWWWW
AEK Athens,10,0,2,340,290,WWLWW
PAOK,8,2,2,331,300,WDWWL
Generic standings
For any other sport — water polo, hockey, rugby, e-sports, a local league. It shows whichever of these columns your data has: rank, team, p, w, d, l, gf, ga, gd, pf, pa, diff, winpct, pts, form, streak.
- Matches played are calculated from
w + d + l, orw + lfor sports without draws; goal and point differences from their for/against columns. - Points are not calculated, because every sport counts them differently — include a
ptscolumn, or tell the ruleset your points system withwin_points,draw_pointsandloss_pointsin the ruleset options. - Order: points (then wins and differences) when there are points; otherwise wins, then fewer losses.
team,w,d,l,pts,form,streak
Falcons,8,1,1,25,WWDWW,W2
Tigers,7,2,1,23,WWWDW,W1
Eagles,6,2,2,20,LWWDW,W1
Rankings
For national team, player, club or federation rankings.
| Key | Column | Calculated when missing |
|---|---|---|
rank |
Position | from the ranking points, highest first |
team |
Team, player or country | |
pts |
Ranking points (decimals are fine) | |
prev_rank |
Previous position | |
movement |
Change in position | prev_rank − rank |
Movement is shown as ▲ 2 for a team that climbed, ▼ 1 for one that dropped, and — when unchanged. If you supply the movement column yourself, use a number (+2, -1, 0).
team,pts,prev_rank
Poland,412.4,1
Italy,398.1,3
France,392.7,2
Brazil,361.9,4
Recent form
The form column shows recent results as coloured badges: W win, D draw, L loss. Write them oldest first; the most recent result, the last one, gets a ring around it.
All of these are understood:
WWDWL
W,W,D,W,L
W W D W L
W-W-D-W-L
win, win, draw, win, loss
ΝΝΙΗΝ (Greek: Ν νίκη, Ι ισοπαλία, Η ήττα)
T (tie) counts as a draw. A value the ruleset cannot read is shown exactly as written.
The streak column (for example W3 or L1) is coloured green for a winning streak and red for a losing one.
Zones: title, qualification, relegation
League tables often colour the places that matter. A zone draws a coloured bar at the start of the row and colours the position number:
- green — title, promotion, play-offs
- blue — qualification, European places, play-in
- red — relegation, play-outs
In the data: a zone column
Add a zone column and write the zone next to each team that has one. The column itself is not shown; whatever you write becomes the tooltip on the position, so you can use your competition's own names:
team,w,d,l,gf,ga,zone
Panathinaikos,5,0,0,12,2,Champions League
PAOK,4,0,1,12,5,Europa League
AEK,3,2,0,13,3,Conference League
OFI,3,1,1,8,4,
Volos,0,2,3,4,9,Relegation
These words choose the colour: champions, champions league, title, promotion, play-offs, up for green; relegation, relegated, play-outs, down for red. Any other text — Europa League, Play-in, Qualification — is blue. You can also write the colour itself: green, blue or red.
Because the zone belongs to the team, it follows the team wherever it finishes.
In the ruleset: by position
To colour places by position instead, add promote, qualify and relegate to the ruleset options: promote=1;qualify=3;relegate=2 colours the leader green, the next three blue and the last two red. A zone in the data still wins for its row.
Highlighting a team
On a club's own site, make its row stand out: add highlight=Team name to the ruleset options. The row gets a light yellow background and the team name is shown in bold. Highlight several teams by separating them with |: highlight=PAOK|Aris. Upper and lower case do not matter.
Team logos
A logo appears next to the team name, never instead of it. There are two ways to add them:
A logo column
Give each team the address of its image. The column itself is not shown.
team,logo,w,d,l
Arsenal,/images/logos/arsenal.png,8,1,1
Chelsea,/images/logos/chelsea.svg,7,2,1
A folder of logos
Put the images in one folder, named after the team in lower case with dashes instead of spaces — Manchester United becomes manchester-united.png — and add logos=1;logo_path=/images/logos/ to the ruleset options (and logo_ext=svg if they are not PNG files). Use the path as your site's visitors see it, including any sub-folder your site lives in.
The folder can also be set for the whole site, in PHP: define('TABULIZER_SPORTS_LOGO_PATH', '/images/logos/');
Ruleset options
Each ruleset tells the table which sport it is with a modification rule such as:
sportstables$sport=football
Add options after it, separated by semicolons. Edit the ruleset in Tabulizer and change the value of its modification rule — or better, copy the ruleset first and change the copy, so that updating this ruleset archive does not overwrite your settings.
sportstables$sport=football;promote=1;qualify=3;relegate=2;highlight=PAOK
| Option | What it does | Example |
|---|---|---|
sport |
football (or soccer), basketball, volleyball, handball, generic, ranking | sport=handball |
promote |
Colour the top N positions green | promote=4 |
qualify |
Colour the next N positions blue | qualify=2 |
relegate |
Colour the bottom N positions red | relegate=3 |
promote_labelqualify_labelrelegate_label |
The tooltip for those zones | promote_label=Champions League |
highlight |
Highlight one or more teams | highlight=PAOK|Aris |
win_pointsdraw_pointsloss_points |
The points system, when points are calculated | win_points=2;draw_points=1 |
logos |
Show logos from a folder | logos=1 |
logo_path |
The folder of the logo images | logo_path=/images/logos/ |
logo_ext |
Their file extension (default png) | logo_ext=svg |
Languages
The column headings follow your site's language. English and Greek are included; any other language uses English. Hover over a heading to see the full name of the column (GD — Goal difference).
To add a language, copy templates/tabulizer/language/sportstables.en.ini to a file named with your language's two-letter code, for example sportstables.de.ini for German, and translate the text in quotes. Keep the keys on the left unchanged and in capitals.
GD="TD"
GD_TITLE="Tordifferenz"
Colours and styling
Every table has the same clean design: a coloured header, alternating row shading, the points column emphasised, and differences coloured green or red. On phones, the position and team stay in view while the rest of the table scrolls sideways.
The colours are CSS variables, so you can change them in your template's CSS without touching the ruleset. For example, to give the football table your club's colours:
table.tabtable-rs_sportstables_1 {
--st-accent: #8b0000; /* header */
--st-accent-soft: rgba(139, 0, 0, .07); /* points column */
--st-highlight: #ffe4e4; /* highlighted team */
}
Other variables: --st-win, --st-draw, --st-loss (form and differences), --st-promote, --st-qualify, --st-relegate (zones), --st-stripe, --st-hover, --st-line and --st-radius. Every cell's content carries a class naming its column (st-team, st-pts, st-form, …) for anything more specific.
Header key reference
| Key | Also accepted | Meaning |
|---|---|---|
rank |
rk, pos, position, # | Position |
team |
club, country, player, name | Team, player or country |
logo |
Logo image address (not shown as a column) | |
zone |
Zone of the team (not shown as a column) | |
p |
pl, played, gp, mp, games, matches | Played |
w |
won, wins | Won |
d |
drawn, draws, draw, t, ties | Drawn / tied |
l |
lost, losses | Lost |
gf / ga |
goals for / goals against | Goals |
gd |
goal difference | Goal difference |
pf / pa |
points for / points against | Points scored and conceded |
diff |
difference | Point differential |
pts |
points | League or ranking points |
winpct |
pct, win%, win percentage | Winning percentage |
gb |
games behind | Games behind the leader |
home / away |
road (for away) | Home / away record |
conf / div |
conference / division | Conference / division record |
form |
last5, last6, last10 | Recent results |
streak |
strk | Current streak |
prev_rank |
prev, previous rank | Previous position |
movement |
change | Change in position |
sf / sa |
sw, sets won / sl, sets lost | Sets won / lost |
sd |
set difference | Set difference |
setratio |
sr, sets ratio | Set ratio |
point_ratio |
pr, points ratio | Point ratio |