prefix . "prihlaseni_2017"; $pocet = $wpdb->get_var("SELECT Count(*) FROM $table"); // echo '

Počet přihlášených: ' . $pocet . '

'; $radky = $wpdb->get_results("SELECT * FROM $table ORDER BY `zaplaceno` DESC, `cislo` ASC, `datumcas` ASC"); if ($radky) { $pocet = 0; echo '

Legenda / Legend

Přihlášený účastník / Registered racer
Přihlášený účastník / Registered racer
Náhradník / Backup racer

 

Kategorie / Categories

M1M2F1F2
Muž / MaleŽena / Female
1977 a mladší /
1977 and younger
1976 a starší /
1976 and older
1977 a mladší /
1977 and younger
1976 a starší /
1976 and older

 

'; foreach ($radky as $radek) { $pocet = $pocet + 1; $cislo = $radek->cislo; $nar=explode('-', $radek->narozeni); $disciplina=$radek->disciplina; if ($disciplina[0]=='C') { $discip='Chodec / Běžec'; } elseif ($disciplina[0]=='K') { $discip='Koloběžkář'; } elseif ($disciplina[0]=='J') { $discip='Jiný vlastní pohyb'; } elseif ($disciplina[0]=='T') { $discip='Tandem'; } else { $discip=$disciplina; } if ($radek->kategorie=='M1') { $kategorie='M1'; } elseif ($radek->kategorie=='M2') { $kategorie='M2'; } elseif ($radek->kategorie=='F1') { $kategorie='F1'; } elseif ($radek->kategorie=='F2') { $kategorie='F2'; } else { $kategorie='--'; } if ($radek->stat=='Czech Republic') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Slovakia') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Switzerland') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Germany') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Russia') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Spain') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Australia') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Poland') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='United Kingdom') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='United States') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Austria') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Hungary') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='New Zealand') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Denmark') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Italy') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Canada') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Belgium') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Finland') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Sweden') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Netherlands') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Ireland') { $stat=''.$radek->stat.''; } elseif ($radek->stat=='Ukraine') { $stat=''.$radek->stat.''; } else { $stat=$radek->stat; } if ($radek->nationality=='Czech Republic') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Slovakia') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Switzerland') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Germany') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Russia') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Spain') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Australia') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Poland') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='United Kingdom') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='United States') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Austria') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Hungary') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='New Zealand') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Denmark') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Italy') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Canada') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Belgium') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Finland') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Sweden') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Netherlands') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Ireland') { $nationality=''.$radek->nationality.''; } elseif ($radek->nationality=='Ukraine') { $nationality=''.$radek->nationality.''; } else { $nationality=$radek->nationality; } if ($pocet <= 159) { if (($pocet % 2) == 1) { echo ''; } else { echo ''; } } else { echo ''; } } echo '
Start. čísloJménoDisciplínaDélka v mílíchRočník (kategorie)Bydliště
' . $cislo . '' . $radek->jmeno . ' ' . $radek->prijmeni . '  ' . $nationality . '' . $discip . '' . $radek->delka . '' . $nar[0] . ' (' . $kategorie . ')' . mb_ucfirst($radek->mesto) . '  ' . $stat . '
' . $cislo . '' . $radek->jmeno . ' ' . $radek->prijmeni . '  ' . $nationality . '' . $discip . '' . $radek->delka . '' . $nar[0] . ' (' . $kategorie . ')' . mb_ucfirst($radek->mesto) . '  ' . $stat . '
' . $cislo . '' . $radek->jmeno . ' ' . $radek->prijmeni . '  ' . $nationality . '' . $discip . '' . $radek->delka . '' . $nar[0] . ' (' . $kategorie . ')' . mb_ucfirst($radek->mesto) . '  ' . $stat . '
'; } else { echo '

Záznamy z databáze se nepodařilo nalézt. / Database records not found.

'; } // echo $current_user->user_login; ?>