Google
Web dns.bdat.net

[PHP-ES] Re: Duda con manejo de base de datos Access. Anexo mi fichero fuente

Write haof XML files: JESE ( jesedog(EN)telefonica.net)
Fecha: mié 26 ene 2005 - 22:46:21 CET


    Rafael:

   Fatal error: Call to undefined function: odbc_connect() in...

---
José Enrique
http://jese.alcorce.org
---
"Rafael" <rsalazar(EN)ucol.mx> escribió en el mensaje 
news:20050125235445.95185.qmail(EN)lists.php.net...
> Ehm... ¿cual es el error que te muestra?
>
> Jese wrote:
>>     Bueno, se ve que no se admiten anexos... Ahí pego el código fuente.-
>> --- 
>>
>> <html>
>>  <head>
>>           <title>Manejo de bases de datos Access vía ODBC</title>
>>   <meta name=description
>>         content='Manejo de bases de datos Access vía ODBC'>
>>   <meta name=keywords
>>         content='Bases de datos, Access, ODBC'>
>>   <meta name=generator
>>         content='mED'>
>>   <meta name=author
>>         content='José Enrique Serrano Expósito'>
>>  </head>
>> <?php // Tratamiento de errores.-
>>  error_reporting( E_ALL );
>> ?>
>>  <body Text    = Black
>>        bgColor = #f1fcd8>
>>
>> <CENTER>
>> <FieldSet style='width:90%'>
>> <Legend align=center>
>>  <font color=fireBrick face='Comic Sans MS' size=3>
>>   <div id=oDivLegend>
>>   </div>
>>  </font>
>> </Legend>
>> <script language='JavaScript'>
>>  oDivLegend.innerText = document.title;
>> </script>
>>  <FONT color=black face='Courier new' size=2>
>> <DIV style='margin-Top:21; margin-Bottom:21;
>>             margin-Left:21; margin-Right:21; background:White'
>>      align=left>
>> <?php
>>  $cDefaultDir = 'd:/HtmL/www.alcorce.org/jese/mdb';
>>  $cMDB        = 'd:/HtmL/www.alcorce.org/jese/mdb/Prueba.mdb';
>>  $cfg_dsn = "DRIVER=Microsoft Access Driver (*.mdb);
>> DBQ=$cMDB;
>> UserCommitSync=Yes;
>> Threads=3;
>> SafeTransactions=0;
>> PageTimeout=5;
>> MaxScanRows=8;
>> MaxBufferSize=2048;
>> DriverId=281;
>> DefaultDir=$cDefaultDir";
>>  $cfg_dsn_login = "";
>>  $cfg_dsn_mdp = "";
>>  echo '$cDefaultDir   == "', $cDefaultDir  , '"<br>';
>>  echo '$cMDB          == "', $cMDB         , '"<br>';
>>  $c = '$cfg_dsn       == "'. $cfg_dsn      . '"<br>'.
>>       '$cfg_dsn_login == "'. $cfg_dsn_login. '"<br>'.
>>       '$cfg_dsn_mdp   == "'. $cfg_dsn_mdp  . '"<br>';
>>  echo $c.'<br>';
>> ?>
>> <TABLE width="95%" border=1 cellspacing=1 cellpadding=1 
>> bgcolor="#FFFFFF">
>>  <TR bgcolor="#CCFFFF">
>>   <th height="22">Id    </th>
>>   <th height="22">Código  </th>
>>   <th height="22">Descripción </th>
>>   <th height="22">Precio  </th>
>>  </TR>
>> <?php
>>  $db_conexion = odbc_connect( $cfg_dsn, $cfg_dsn_login, $cfg_dsn_mdp )
>>                 or die( "No se a podido enlazar con la base de datos" );
>>  $cur = odbc_exec( $db_conexion,
>>                    "select Id,Codigo,Descripcion,Precio from 
>> Productos" );
>>  while( odbc_fetch_row( $cur ) ) {
>>   $Id          = odbc_result( $cur, 1 );
>>   $Codigo      = odbc_result( $cur, 2 );
>>   $Descripcion = odbc_result( $cur, 3 );
>>   $Precio      = odbc_result( $cur, 4 );
>>   print("<TR>");
>>   print(" <td>$Id</td>");
>>   print(" <td>$Codigo</td>");
>>   print(" <td>$Descripcion</td>");
>>   print(" <td>$Precio</td>");
>>   print("</TR>");
>>  }
>>  odbc_close( $db_conexion );
>> ?>
>> </TABLE>
>> </DIV>
>>  </FONT>
>> </FieldSet>
>> </CENTER>
>>
>>  </body>
>> </html>
>>
>> ---
>> José Enrique
>> http://jese.alcorce.org
>> ---
>>   "Jese" <jesedog(EN)telefonica.net> escribió en el mensaje 
>> news:20050125195228.40521.qmail(EN)lists.php.net...
>>       Hola a todos:
>>
>>       ¿Alguien que me ayude y me diga en qué puede fallar el fichero que 
>> anexo?
>>
>>       Gracias de antemano.
>>   ---
>>   José Enrique
>>   http://jese.alcorce.org
>>   ---
>
> -- 
> J. Rafael Salazar Magaña
> Aplicaciones Win32 y Desarrollo Web
> CENEDIC, Universidad de Colima
> 
-- 
PHP Spanish Localization Talk Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Este archivo fue generado por hypermail 2.1.7 : sáb 19 mar 2005 - 01:01:24 CET