ID:               46939
 Updated by:       cel...@php.net
 Reported By:      lunter at interia dot pl
-Status:           Assigned
+Status:           Bogus
 Bug Type:         PHAR related
 Operating System: WinXP
 PHP Version:      5.3.0alpha3
 Assigned To:      cellog
 New Comment:

This is an intended side effect.  .zip and .tar-based phar archives
will not work if .phar is not in the name, and so allowing creation of
them is not allowed.  If we allowed this for phar-based phar archives,
it would be inconsistent and confusing.

We are, of course, in alpha stage, but it would be a major change to do
this.

What is the workaround?

blah.phar.php or blah.phar.php5 or blah.phar.php6 all work.  If you
would like to discuss alternatives, I am happy to do so, either on
intern...@lists.php.net or through email at cel...@php.net


Previous Comments:
------------------------------------------------------------------------

[2008-12-24 16:06:46] lunter at interia dot pl

Description:
------------
This PHP code triggers:

Fatal error: Uncaught exception 'UnexpectedValueException' with message
'Cannot create phar 'core.php', file extension (or combination) not
recognised' in C:\htdocs\a\!phar2.php:2 Stack trace: #0
C:\htdocs\a\!phar2.php(2): Phar->__construct('core.php') #1 {main}
thrown in C:\htdocs\a\!phar2.php on line 2

but *.php files work as good as *.phar

when using:
1) http://web.com/file.php/index.php
2) require('phar://file.php');

Reproduce code:
---------------
<?
 $p=new Phar('core.php');
?>

Expected result:
----------------
NO Fatal error wheh extension is *.php (*.php5, *.php6)

Actual result:
--------------
Fatal error wheh extension is *.php (*.php5, *.php6)


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=46939&edit=1

Reply via email to