mirror of
https://github.com/JeroenED/libpairtwo.git
synced 2024-11-15 11:27:50 +01:00
Updated Showing the pairings of a specific round (markdown)
parent
2a72f7aa9e
commit
cf06eb0a58
@ -10,11 +10,12 @@ When you have the round object you can the `Round::GetPairings()` method to get
|
|||||||
````php
|
````php
|
||||||
<?php
|
<?php
|
||||||
require_once('vendor/autoload.php');
|
require_once('vendor/autoload.php');
|
||||||
use JeroenED\Libpairtwo\Sws;
|
use JeroenED\Libpairtwo\IOFactory;
|
||||||
use JeroenED\Libpairtwo\Enums\Result;
|
use JeroenED\Libpairtwo\Enums\Result;
|
||||||
|
|
||||||
$sws = Sws::readSws('mycompetition.sws');
|
$reader = IOFactory::createReader('Pairtwo-6');
|
||||||
$tournament = $sws->getTournament();
|
$reader->read('mycompetition.sws');
|
||||||
|
$tournament = $reader->getTournament();
|
||||||
$pairings = $tournament->getRoundByNo($_GET['round'])->getPairings();
|
$pairings = $tournament->getRoundByNo($_GET['round'])->getPairings();
|
||||||
|
|
||||||
foreach($pairings as $pairing) {
|
foreach($pairings as $pairing) {
|
||||||
|
Loading…
Reference in New Issue
Block a user