Retroceder   Foros del Web > Programación para sitios web > PHP

Respuesta
 
Herramientas Desplegado
Antiguo 25-abr-2008, 07:21   #1 (permalink)
eddyri21 ha deshabilitado el karma
 
Avatar de eddyri21
 
Fecha de Ingreso: abril-2008
Mensajes: 18
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL

que es lo que faltaria.. porq no tengo idea

<?php
$int_periodo=1;
$enlace=mysql_connect("localhost:3306","root","");
mysql_select_db("db_evaluacion");
$str_sql_bus_pre = "CALL RHABuscar_Preguntas(".$int_periodo.",1,'A')";
$resultado=mysql_query($str_sql_bus_pre,$enlace);
#echo $str_sql_bus_pre;
$int_preguntas_a=0;
while($preguntas = mysql_fetch_array($resultado) ) {

echo "
<tr>
<td colspan='2' rowspan='13' align='center' valign='top'></td>
<td height='21'><div align='center'><strong>".$preguntas['indice']."</strong></div></td>
<td width='368'>".$preguntas['preguntas']."</td>
<td width='14'>&nbsp;</td>
<td colspan='2' valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='1'></td>
<td valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='2'></td>
<td valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='3'></td>
<td valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='4'></td>
<td colspan='2' valign='middle' align='center'><input name='pregunta_b[".$int_preguntas_a."]' type='radio' value='5'></td><input type='hidden' name='cod_pre_a[".$int_preguntas_a."]' value='".$preguntas['codigo']."' >
</tr>";
$int_preguntas_b++;
}
?>


GRACIAS!
eddyri21 está desconectado   Responder Citando
Antiguo 25-abr-2008, 08:03   #2 (permalink)
jago86 ha deshabilitado el karma
 
Avatar de jago86
 
Fecha de Ingreso: abril-2008
Ubicación: Ibarra - Ecuador
Mensajes: 42
Re: Warning: mysql_fetch_array(): supplied argument is not a valid MySQL

Pon la linea de la consulta asi para ver si te devuelve algun error en la misma,
$resultado=mysql_query($str_sql_bus_pre,$enlace) or die (mysql_error());
jago86 está desconectado   Responder Citando
Respuesta
No hay votos aún.


Herramientas
Desplegado

Normas de Publicación
No puedes crear nuevos temas
No puedes responder temas
No puedes subir archivos adjuntos
No puedes editar tus mensajes

BB code is Activado
Caritas están Activado
[IMG] está Activado
Código HTML está Desactivado


La Zona horaria es GMT -6. Ahora son las 08:48.


Message Board Statistics

LinkBacks Enabled by vBSEO 3.1.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93