}
    if (is_numeric($id) && is_numeric($match)) {
        $db->delete("{$dbprefix}matchs_commentaires");
        $db->where("id = {$id} and matchi = {$match}");
        $db->exec();
    }
    /*** redirection ***/
    js_goto("?page=matchs_commentaires&match={$match}&header=win");
} else {
    echo "<p class=title>.:: {$strCommentairesMatch} {$match} ::.</p>";
    /*** affichage des commentaires ***/
    if (!$start) {
        $start = 0;
    }
    $nb_max = $config['nb_matchs_commentaires_max'];
    $nb_total = nb_matchs_commentaires($match);
    $db->select("*");
    $db->from("{$dbprefix}matchs_commentaires");
    $db->where("matchi = {$match}");
    $db->order_by("id ASC LIMIT {$start},{$nb_max}");
    $res = $db->exec();
    if ($db->num_rows($res) == 0) {
        echo "<table cellspacing=0 cellpadding=0 border=0>";
        echo "<tr><td class=title><div align=justify>{$strPasDeCommentaire}</div></td></tr>";
        echo "</table><br>";
    } else {
        echo "<table align=center width=300 border=0 cellspacing=0 cellpadding=0>";
        echo "<tr><td class=title align=center>{$strCommentaires}</td></tr>";
        echo "<tr><td>";
        $nbCommentaires = 0;
        while ($commentaire = $db->fetch($res)) {
Esempio n. 2
0
                echo "<font color=red><b>{$strConflit}</b></font>";
            }
            if ($match->status == "T") {
                echo "<font color=red><b>{$strTermine}</b></font>";
            }
        }
        echo "</td></tr>";
        echo "</table>";
        echo "</td></tr>";
        if ($op == 'admin') {
            echo "<tr><td class=text colspan=5 align=center><input type=submit value=\"{$strModifier}\">&nbsp;&nbsp;&nbsp;<input type=submit value=\"{$strValider}\" onclick=\"document.form.op2.value='valider';return true;\"></td></tr>";
        } elseif ($report_type == 1) {
            echo "<tr><td class=text colspan=5 align=center><input type=submit value=\"{$strValiderScore}\"></td></tr>";
        } elseif ($report_type == 2) {
            echo "<tr><td class=text colspan=5 align=center><input type=submit value=\"{$strValiderScore}\" onclick=\"document.form.op2.value='valider';return true;\">&nbsp;&nbsp;&nbsp;<input type=submit value=\"{$strRefuserScore}\" onclick=\"document.form.op2.value='refuser';return true;\"></td></tr>";
        }
        echo "<tr><td class=text colspan=5 align=center>";
        if ($modecommentaire_tournois != 'N') {
            echo "<img src=\"images/icon_comment.gif\" border=0 align=absmiddle> <a href=\"#\" onclick=\"javascript:ouvrir_fenetre('?page=matchs_commentaires&match={$match->id}&header=win','fichiers',400,600)\">{$strCommentaires} ? (" . nb_matchs_commentaires($match->id) . ")</a>&nbsp&nbsp;";
        }
        if ($modefichier_tournois != 'N' && ($match->status == "T" || $op == 'admin')) {
            echo "<img src=\"images/icon_attach.gif\" border=0 align=absmiddle> <a href=\"#\" onclick=\"javascript:ouvrir_fenetre('?page=matchs_browser&match={$match->id}&header=win','fichiers',300,600)\">{$strFichiersAttaches}</a>";
        }
        echo "</td></tr>";
        echo "</td></tr>";
        echo "</table>";
        echo "</td></tr></table>";
        echo "</td></tr></table>";
        echo "</form>";
    }
}