Palabras rescatadas
|
|
|
$mysql=new database();
$mysql->conectar($config['basededatos']['servidor'],$config['basededatos']['usuario'],$config['basededatos']['password']);
$mysql->trincarbase($config['basededatos']['db']);
if (isset($_GET['letra']) AND $_GET['letra']!="")
{
$SQL="SELECT * FROM ".$config["tablas"]["diccionario"]." WHERE borrado=0 AND palabra LIKE '".$_GET['letra']."%' ORDER BY fecha DESC";
}
else
{
$SQL="SELECT * FROM ".$config["tablas"]["diccionario"]." WHERE borrado=0 ORDER BY fecha DESC";
}
$mysql->consultar($SQL);
if ($mysql->numfilas()>0){
echo ("\n");
echo ("\n");
echo ("\n");
echo ("\n");
echo (" | \n");
echo ("\n");
echo ("\n");
echo (" | \n");
echo (" \n");
$alternar=1;
while ($fila=$mysql->trincarfila())
{
if ($alternar==0)
{
$alternar=1;
echo ("\n");}
else{
$alternar=0;
echo (" \n");}
echo ("\n");
echo ($fila["palabra"]);
echo (" | \n");
echo ("\n");
echo ($fila["significado"]);
echo (" | \n");
echo (" \n");
echo ("");
echo ("\n");
echo (" ");
echo (" | \n");
echo ("\n");
echo (" ");
echo (" | \n");
echo (" ");
}
echo (" \n");
unset ($_POST["enviar"]);
$mysql->desconectar();
}
?>
|
|