Greg Beaver
9320ac9893
remove FIXME - it's been fixed
2007-12-29 02:04:09 +00:00
Greg Beaver
3dcee1c8c7
fix index/custom 404 page
2007-12-29 02:01:12 +00:00
Greg Beaver
06a98d96c7
update proto, arginfo for webPhar
2007-12-29 01:37:12 +00:00
Greg Beaver
acc44900de
add vastly improved 404 handling
2007-12-29 01:35:46 +00:00
Greg Beaver
60dc8e5ff4
fix redirect to index file
2007-12-28 23:33:15 +00:00
Greg Beaver
e1a41da652
fix on windows
...
# it works! it works!
2007-12-26 16:59:01 +00:00
Greg Beaver
e861913e39
fix windows build
...
# there HAS to be a better way to do this...
2007-12-24 21:40:54 +00:00
Greg Beaver
4ae47c1df9
remove unused variable
2007-12-24 20:48:12 +00:00
Greg Beaver
5200481aaf
fix mem leak
2007-12-24 20:30:44 +00:00
Greg Beaver
02c7ff1343
complete re-factoring of front controller. Now it is done with
...
Phar->webPhar():
<?php
Phar::webPhar();
__HALT_COMPILER();
With the above stub, the default front controller will kick in. An array of mime type overrides, and another
array mapping phar file entry -> redirected entry can be used to further customize
[DOC]
2007-12-23 21:12:42 +00:00
Greg Beaver
d443c76bed
new test for front controller
2007-12-22 07:47:15 +00:00
Greg Beaver
8e4cc4b3dd
first attempt at major new feature: default front controller for web
...
Currently, an entire phar entry is leaked for no obvious reason, otherwise it works. Sample code:
The phar has to be created using Phar->useFrontController(); and the stub performs actual resolution of which file to load:
<?php
Phar::mapPhar();
include 'phar://' . __FILE__ . '/' . substr($_SERVER['REQUEST_URI'], strlen(basename(__FILE__)));
__HALT_COMPILER();
?>
Phar automatically determines mime type from the file extension and either parses or displays the file. Modification of REQUEST_URI
and other variables should happen in the stub
[DOC]
2007-12-22 07:46:53 +00:00
Greg Beaver
245ca069c8
same fix we used in linux to make all extension deps optional
2007-12-21 19:02:20 +00:00
Greg Beaver
185a4a8309
on second thought, hooking into getcwd() is a bad idea, who uses this for code loading, anyways?
2007-12-21 04:49:25 +00:00
Greg Beaver
0d830a27ea
implement cleaning of crap paths - major functionality boost
2007-12-20 23:12:40 +00:00
Greg Beaver
0bfc046eac
remove minor (and unnecessary I might add) windows compile warnings
2007-12-20 04:12:23 +00:00
Greg Beaver
d4eccb4471
holy cow - include/fopen/cwd magic fully working on unix now for windows testing
2007-12-19 04:37:25 +00:00
Greg Beaver
2222da9493
making progress (include magic works)
2007-12-19 03:17:05 +00:00
Greg Beaver
0c51d58138
[unfinished] magically handle getcwd() and fopen() with include_path inside phar
...
this work is incomplete, but compiles and existing tests pass
2007-12-18 17:01:24 +00:00
Greg Beaver
d757f6ee5e
oops, need to make these things optional, not required
2007-12-18 05:32:11 +00:00
Greg Beaver
7fa0b43518
fully implement Phar->copy(), fix test
2007-12-16 06:31:00 +00:00
Greg Beaver
427e54dcd9
add failing test
2007-12-16 01:11:50 +00:00
Greg Beaver
f11103a9a1
Phar::copy() [not yet working]
2007-12-16 00:57:39 +00:00
Greg Beaver
bb4096ff29
Phar->buildFromIterator now can also accept a stream handle as a value in addition
...
to a file path (string) or SplFileInfo object
[DOC]
2007-12-14 19:45:22 +00:00
Greg Beaver
f01adb0048
fix test
2007-12-14 18:54:54 +00:00
Greg Beaver
47cef85c22
fix alias overloading detection on windows
2007-12-14 18:42:57 +00:00
Greg Beaver
052dcfcbae
fix test
2007-12-14 18:37:49 +00:00
Greg Beaver
4fb3122b16
fix terrible logic discovered in windows testing (not sure how it ever worked on unix)
2007-12-14 18:34:12 +00:00
Greg Beaver
708569029c
windows fixes #2 (thanks Steph you rule)
2007-12-14 05:45:48 +00:00
Greg Beaver
c6fe26af37
windows fixes (thanks Steph you rule)
2007-12-14 05:39:20 +00:00
Greg Beaver
16c8adf0c1
fix test
2007-12-14 05:22:53 +00:00
Greg Beaver
38bf150e4d
remove stupid*$(# debug code
2007-12-14 05:00:59 +00:00
Greg Beaver
2c77090174
better fix, revert unintentional commit to Makefile.frag
2007-12-14 04:10:14 +00:00
Greg Beaver
63f3d5958d
fix build on windows, fix segfault in tsrm by uninitialized pointer
2007-12-14 04:08:34 +00:00
Greg Beaver
3b356d5ed8
new test
...
now, SplDirectoryIterator can be used directly with Phar->buildFromIterator() in order to populate the
files in a phar archive. When combined with a RegexIterator and other filters, it becomes very easy to create
a phar archive with 1 line of code
[DOC]
2007-12-13 05:22:06 +00:00
Greg Beaver
6e78306595
new test
2007-12-13 01:20:25 +00:00
Greg Beaver
d243f9ff99
code re-organize to make it more logical
2007-12-13 01:16:56 +00:00
Greg Beaver
4f2d1674ca
new test
2007-12-13 01:14:13 +00:00
Greg Beaver
c1a6037cf2
fix test, new test
2007-12-13 01:12:10 +00:00
Greg Beaver
38b35f1448
Phar->buildFromIterator: fix another mem leak, fix test
2007-12-13 01:05:59 +00:00
Greg Beaver
5051732d4c
kill 1 memleak
2007-12-13 01:01:27 +00:00
Greg Beaver
463731e2de
Phar->buildFromIterator: use spl_iterator_apply(), add 4 tests (mem leaks not yet fixed in the 4th)
2007-12-13 00:54:15 +00:00
Greg Beaver
5af85b4f8f
implement Phar::buildFromIterator()
...
first argument is an iterator that returns as values paths to files to add to the phar archive
the key should be the path that the file should be saved as within the phar archive
if the optional second parameter is passed, then the key is ignored and substr(value, strlen(base_directory)) is
used as the save path within the phar archive
[DOC]
2007-12-12 18:01:40 +00:00
Greg Beaver
8a614e30db
use thread-safe global var to store zend_compile_file, and restore the current zend_compile_file, not the one we
...
found in MINIT
2007-12-11 19:28:35 +00:00
Greg Beaver
47d859ced2
use stream_copy_to_stream again, figured out how to make the stupid filters work
2007-12-11 19:21:01 +00:00
Greg Beaver
f8fc8fbd69
fix test in 5.3+
2007-12-11 19:19:47 +00:00
Greg Beaver
30fa2bda71
add note about new include functionality
2007-12-11 03:12:42 +00:00
Greg Beaver
688aef57f8
add the ability to automatically resolve includes inside a phar to files within that phar, so
...
no code modification is needed to include/require
2007-12-09 21:57:44 +00:00
Greg Beaver
84c3c96754
add helper phars for test
2007-11-25 05:25:04 +00:00
Greg Beaver
48ca9c876c
new test to verify signature algo parsing works
2007-11-25 05:24:50 +00:00