Hola lolaloleitor!
Necesito tu ayuda, he probado tu script y no consigo hacerlo correr te indico los pasos dados:1, Edito tu script como excel_import.php e incluyo mis datos dentro de este asi:
Cita: <?php
function conectar() // esta os la sabeis
{
$dbhost="localhost";
$user="root";
$pass="root";
$db="osCommercebd";
no listo todo el codigo, solo lo cambiado.
2.Lo guardo en la carpeta del localhost y desde el navegador ejecuto el tipico :
Cita: /localhost/excel_import.php
Y el error que me sale aproximadamente unas 50 lineas es este:
Cita: Warning: fopen(archivo.csv) [function.fopen]: failed to open stream: No such file or directory in C:\wamp\www\excel_import.php on line 35
Warning: fgetcsv() expects parameter 1 to be resource, boolean given in C:\wamp\www\excel_import.php on line 37
Warning: Invalid argument supplied for foreach() in C:\wamp\www\excel_import.php on line 41
Warning: fgetcsv() expects parameter 1 to be resource, boolean given in C:\wamp\www\excel_import.php on line 37
Warning: Invalid argument supplied for foreach() in C:\wamp\www\excel_import.php on line 41 . . . (hasta 50 veces )
Fatal error: Maximum execution time of 30 seconds exceeded in C:\wamp\www\excel_import.php on line 37
¿Sabes que es lo que estoy haciendo mal?
Gracias por adelantado.