91 lines
2.1 KiB
PHP
Executable File
91 lines
2.1 KiB
PHP
Executable File
<?
|
|
include("mysql_compat.php");
|
|
$db=mysql_connect('o2000', 'jmevel', 'jmevel01');
|
|
mysql_select_db("tournois_tennis_v2", $db);
|
|
$s='\'';
|
|
?>
|
|
<html>
|
|
|
|
<head>
|
|
<meta http-equiv="Content-Language" content="fr">
|
|
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
|
|
<title>pour consulter la base</title>
|
|
</head>
|
|
|
|
<body background="../images/balle_raquette3.jpg">
|
|
|
|
|
|
<?
|
|
include("mysql_compat.php");
|
|
$titre="Bienvenue sur la FAQ"; include("../enTete.php");
|
|
print "<TR><TD>RUBRIQUE : <B>$name</B> pour le sujet de l'article : <B>$sujet_art</B></TD></TR>";
|
|
$sql="SELECT * FROM kb WHERE id_art=$id_art";
|
|
$result=mysql_query($sql,$db);
|
|
while ($item = mysql_fetch_array($result))
|
|
{
|
|
$title = $item["title"];
|
|
$content = $item["text"];
|
|
$date = $item["date"];
|
|
#$content=htmlescape($content);
|
|
print "<TABLE width=100% border=0 bgcolor='#FFFFFF'>";
|
|
print "<BR>";
|
|
print "<BR>";
|
|
print "<TR><TD>Information : <B>$title </B>($date)</TD><TD><A HREF=\"edit_article.php?id_art=$id_art\"></TD></TR>";
|
|
print "</TABLE>";
|
|
|
|
print "<TABLE width=\"100%\" border=1 bgcolor='#FFFFFF'>";
|
|
//print "<TR><TD><B>Réponse du $date </B></TD></TR>";
|
|
print "<TR><TD>" . nl2br($content) . "</TD></TR>";
|
|
}
|
|
#print "<TR><TD>" . $content . "</TD></TR>";
|
|
print "</TABLE>";
|
|
include("../piedDePage.php");
|
|
?>
|
|
|
|
<script language="javascript">
|
|
|
|
function confirmThis(url) {
|
|
if (confirm("Etes-vous sur de vouloir supprimer l'article ?", "Aie, Aie, Aie !!!", "Aie, Aie, Aie !!!")) {
|
|
window.location = url;
|
|
}
|
|
}
|
|
</script>
|
|
|
|
|
|
<?
|
|
include("mysql_compat.php");
|
|
function htmlescape ($input) {
|
|
|
|
$output = '';
|
|
|
|
while(1) {
|
|
if($input == '')
|
|
break;
|
|
|
|
$ch = substr($input,0,1);
|
|
$templen = strlen($input) - 1;
|
|
$input = substr($input,1,$templen);
|
|
|
|
|
|
if($ch == "\\xA9") $ch = '©';
|
|
if($ch == "\\xA8") $ch = '®';
|
|
#if($ch == '&') $ch = '&';
|
|
if($ch == '"') $ch = '"';
|
|
if($ch == '<') $ch = '<';
|
|
if($ch == '>') $ch = '>';
|
|
|
|
#if(ord($ch) > 126) $ch = '';
|
|
#if(ord($ch) < 9) $ch = '';
|
|
#if(ord($ch) == 11) $ch = '';
|
|
#if(ord($ch) > 14 && ord($ch) < 32) $ch = '';
|
|
|
|
$output = $output . $ch;
|
|
}
|
|
|
|
|
|
return($output);
|
|
}
|
|
/**********************************************************************/
|
|
|
|
?>
|