php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #52683 couldn't create phar on osx
Submitted: 2010-08-24 05:04 UTC Modified: 2010-08-24 13:12 UTC
From: jinmoku at hotmail dot com Assigned:
Status: Not a bug Package: PHAR related
PHP Version: 5.3.3 OS: OSX 10.6.4
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: jinmoku at hotmail dot com
New email:
PHP Version: OS:

 

 [2010-08-24 05:04 UTC] jinmoku at hotmail dot com
Description:
------------
when i'am create phar on osx (php 5.3.3), some weird charaters apprear (in the phar)

I can't copy phar's source (weird charaters dont pass)

phar link : http://backfront.org/bugs/MyPhar.phar


Test script:
---------------
$phar = new Phar('MyPhar.phar');

$index = <<<DOC
<?php
	echo 'hello';
DOC;
$phar->addFromString('index.php', $index);

require_once('MyPhar.phar');

Expected result:
----------------
hello

Actual result:
--------------
��????

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-08-24 13:12 UTC] johannes@php.net
-Status: Open +Status: Bogus
 [2010-08-24 13:12 UTC] johannes@php.net
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

You have to use the phar:// stream to access the contents
 [2010-08-24 13:39 UTC] jinmoku at hotmail dot com
documentation said :

<?php
include 'coollibrary.phar';
?>

http://www.php.net/manual/en/phar.using.intro.php

and  
require_once('phar://MyPhar.phar/index.php');
don't work too
 [2010-08-26 04:53 UTC] jinmoku at hotmail dot com
in make test :
FAIL Phar: test readfile() interception [ext/phar/tests/readfile.phpt]

ACTUAL RESULT :
????

I'm sorry but it's really a bug
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Jan 15 11:01:31 2025 UTC