File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / ext / phar / tests / files / blog.phar.inc
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Tue Feb 21 23:48:00 2012 UTC (12 years, 10 months ago) by misho
Branches: php, MAIN
CVS tags: v5_4_3elwix, v5_4_29p0, v5_4_29, v5_4_20p0, v5_4_20, v5_4_17p0, v5_4_17, v5_3_10, HEAD
php

<?php

$fname = dirname(__FILE__) . '/blog.phar';
@unlink($fname);

$phar = new Phar($fname);
$phar->setStub('<?php
Phar::interceptFileFuncs();
if(file_exists(dirname(__FILE__) . "/files/config.xml")) {
    Phar::mount("config.xml", dirname(__FILE__) . "/files/config.xml");
}
Phar::webPhar("blog", "index.php");
__HALT_COMPILER(); ?>');
$phar['index.php'] = '<?php if (!file_exists("config.xml")) {
	include "install.php";
	exit;
}
var_dump(str_replace("\r\n", "\n", file_get_contents("config.xml")));
?>';
$phar['install.php'] = '<?php echo "install\n"; ?>';

?>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>