Ver Mensaje Individual
  #3 (permalink)  
Antiguo 05/12/2006, 11:01
IntentoAprender
 
Fecha de Ingreso: diciembre-2006
Mensajes: 2
Antigedad: 17 aos, 4 meses
Puntos: 0
sigue dandome errores

Muchas gracias Yoelis por responderme,

La cosa es que estoy intentando hacer una web con dremweaver, y al hacer un "juego de registros" me da error cuando en el SELECT incluyo al archivo, indicando "Se ha producido un error no identificado". Si no lo incluyo, no me da problemas, pero claro, no me deja seleccionarlo de la BBDD. Luego miro sta a travs de mysql y est all el archivo.

Intento entonces engaar un poco al dreamweaver, y selecciono slo texto de la BBDD, pero luego en la vista de cdigo, introduzco en el SELECT el archivo, es decir, la query inicial era...
SELECT TITULO FROM inventos,
y la cambio por...
SELECT TITULO, ARCHIVO FROM inventos, donde ARCHIVO es un blob.

Luego los quiero introducir en una tabla, con el cdigo siguiente:


<?php require_once('Connections/INVENTOS.php'); ?>
<?php
mysql_select_db($database_INVENTOS, $INVENTOS);
$query_Recordset1 = "SELECT TITULO, ARCHIVO FROM inventos";
$Recordset1 = mysql_query($query_Recordset1, $INVENTOS) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "-transitional.dtd">
<html xmlns="">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Documento sin t&iacute;tulo</title>
</head>

<body>
<table width="200" border="1">
<tr>
<th scope="col"><?php echo $row_Recordset1['TITULO']; ?></th>
<th scope="col"><?php echo $row_Recordset1['ARCHIVO']; ?></th>
</tr>
<tr>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
</table>
</body>
</html>
<?php
mysql_free_result($Recordset1);
?>


Lo ejecuto, y en el cdigo html del navegador me genera lo siguiente:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "-transitional.dtd">
<html xmlns="">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Documento sin t&iacute;tulo</title>
</head>

<body>
<table width="200" border="1">
<tr>
<th scope="col">Fregasuelos</th>
<th scope="col"> JFIF   ` ` LEAD Technologies Inc. V1.01   
 $.' "+"(6(+/1343&8<82<.231


1!!111111111111111111111111111111111111111111111 11111  
  
  } !1AQa"q2#BR$3br
%&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz   w !1AQaq"2B #3Rbr
$4%&'()*56789:CDEFGHIJSTUVWXYZcdefghijstuvw xyz  V ]    ? Z8<>"oZXxXI z{Wd09S
sdbV"I6MR@-p^OS<4MԓZ\%QSĚJ y΢OU` ]$} GV9Nʢo]}ȿi{kx*."}kѥZUzrO9CV'*H
( #.p$JK '@{I]&M:uӤBn]wRBĐIJIsi]xhBS\\7u LGonNzת/ghݶ2Ւwg*e
*ż:[nQ3F۶z&+%Ml /"Q)76i n-=O_QϢi,Mxȩ]j~#U15/ A}j./txԖ̮mpjcWqJȷG*r뢹^][t:࿸^ +zݛP֪;w;FVX G`}As^5Jҡ
KC~7
c* 8D Fn;{gy2I5@۹7ty~r eW}1RA_ ?|oY[zM.1ǽN9#tP/]lD]HҼ1kݬ ` J
u?iΗ9>Ҵl<p[MtLz_@M-M
( 
( 
( 
(</th>
</tr>
<tr>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
</table>
</body>
</html>