php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #7620 dbase_get_record_with_names crashes php
Submitted: 2000-11-03 08:46 UTC Modified: 2001-10-09 04:42 UTC
From: swift at mindless dot com Assigned:
Status: Closed Package: dBase related
PHP Version: 4.0.3pl1 OS: Win98Me
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: swift at mindless dot com
New email:
PHP Version: OS:

 

 [2000-11-03 08:46 UTC] swift at mindless dot com
Hi!

When I use dbase_get_record_with_names instead of dbase_get_record on one of my database to import, php crashes!

If you need it, I could send you the dbase-database that caused the problem - please mail me if I should do so.

... tobias wiersch from germany

PS: I used the following code (example):

<?php

  include('head.php'); include('body.php');
  include('maincfg.php');

  $dbf = dbase_open('d:/3dx/php/product.dbf', 0)
    or die('there is no product.dbf!');

  $RecNum = dbase_numrecords($dbf);

  for($i=1; $i <= $RecNum; $i++)
  {
    $row = dbase_get_record_with_names($dbf, $i);
    echo $row["prod_no"] . "<br>";
  }

  dbase_close($dbf);

?>

---------------- but this is working:

<?php

  include('head.php'); include('body.php');
  include('maincfg.php');

  $dbf = dbase_open('d:/3dx/php/product.dbf', 0)
    or die('there is no product.dbf!');

  $RecNum = dbase_numrecords($dbf);

  for($i=1; $i <= $RecNum; $i++)
  {
    $row = dbase_get_record($dbf, $i);
    echo $row[0] . "<br>";
  }

  dbase_close($dbf);

?>

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-10-09 04:42 UTC] sniper@php.net
Please try the latest CVS snapshot from 
http://snaps.php.net/ as this should now be fixed.

--Jani
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 17:01:29 2024 UTC