php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #61180 $mysqli object created in auto_prepend_file closes before auto_append_file
Submitted: 2012-02-25 00:38 UTC Modified: 2014-12-30 10:41 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: khaos337 at gmail dot com Assigned:
Status: No Feedback Package: *General Issues
PHP Version: 5.3.10 OS: Free BSD
Private report: No CVE-ID: None
 [2012-02-25 00:38 UTC] khaos337 at gmail dot com
Description:
------------
If you initialize a $mysqli object in an auto_prepend_file it is unavailable in 
and auto_append_file, even though auto_prepend_file and auto_append_file

Test script:
---------------
.htaccess:
php_value  auto_prepend_file /path/to/file/prepend.php
php_value  auto_append_file /path/to/file/append.php

prepend.php:
$mysqli = new mysqli('localhost', 'user', 'pass', 'DBASE');

append.php:
$mysqli->close(); (or any mysqli method)

Expected result:
----------------
No Errors

Actual result:
--------------
Warning: mysqli::close() [mysqli.close]: Couldn't fetch mysqli in 
/path/to/file/append.php

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-12-06 08:14 UTC] mike@php.net
-Status: Open +Status: Feedback
 [2013-12-06 08:14 UTC] mike@php.net
Please try using this snapshot:

  http://snaps.php.net/php-trunk-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/

Cannot reproduce.
 [2014-12-30 10:41 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Oct 10 13:01:26 2024 UTC