|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
Fogox Smarty Rookie
Joined: 09 Apr 2008 Posts: 6
|
Posted: Fri Apr 11, 2008 8:52 pm Post subject: heeelllppp!!!! Smarty... Conex |
|
|
I need help in this code I am again with smarty wanted to know if I offered their help,
I have also problems with the connection to mysql smarty ...
In the tutorial does not explain well the theme of connection, I leave in your hands
Forgive my English,
Thank you
<?php
# Eial 2004 la versión orginial se encuentra en # Configurar las dos lineas siguientes
@mysql_connect('localhost','xxxxx','xxxxx') or die('No se puede conectar con el servidor mysql');
@mysql_select_db('xxxx') or die('No se puede seleccionar la base de datos especificada');
$datos = ($_GET['id']) ? 'id=' . mysql_escape_string($_GET['id']) : "nombre='" . mysql_escape_string($_GET['nombre']) . "'";
$resultado = @mysql_query("SELECT imagen,tipo FROM xxxx WHERE " . $datos);
$imagen = @mysql_fetch_assoc($resultado) or die('Imagen inexistente');
header("Content-type: $imagen[tipo]");
print $imagen['imagen'];
?> |
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|