php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #54362 Documentation example bug using '$error' when it's not instataited
Submitted: 2011-03-23 20:28 UTC Modified: 2011-03-24 07:32 UTC
From: bugs dot php dot net at creuzer dot com Assigned:
Status: Not a bug Package: Documentation problem
PHP Version: Irrelevant OS:
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: bugs dot php dot net at creuzer dot com
New email:
PHP Version: OS:

 

 [2011-03-23 20:28 UTC] bugs dot php dot net at creuzer dot com
Description:
------------
---
From manual page: http://www.php.net/function.sqlite-exec#Examples
---

     exit("Error in query: '$error'");

The $error variable is out of context. A non-broken code example should be provided.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-03-24 07:32 UTC] aharvey@php.net
-Status: Open +Status: Bogus
 [2011-03-24 07:32 UTC] aharvey@php.net
Both code examples look fine to me and execute normally: $error is an out parameter from sqlite_exec() and SQLiteDatabase::queryExec() and is used appropriately.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 23:01:27 2024 UTC