News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Zoe Slattery's Blog:
So phar so good
January 13, 2009 @ 11:11:54

In a recent post to her blog Zoe Slattery looks at a way to provide users with a single-file approach to installing an application. Her choice was phar.

I've just finished converting a small procedural application, designed to be run from the command line, to PHP5 . I wanted a way to give users a single file to execute and as phar is included in PHP5.3 I decided to try to use it.

She includes the tree structure for the application and steps through the process she used to make the archive - a call to buildFromDirectory, making a new phar object, adding the contents of files into it and building out a stub that maps the command-line call on the archive to a certain script.

0 comments voice your opinion now!
phar tutorial archive example script


blog comments powered by Disqus

Similar Posts

Pádraic Brady's Blog: Extending the Mapper: Stars and Planets

Kristina Chodorow's Blog: Writing a PHP Extension (Four Part Series)

Edin Kadribasic's Blog: PHP 4.4.3 for Windows with 5.0.22 MySQL libraries

Lorna Mitchell's Blog: Idiot-Proof Deployment with Phing

SitePoint PHP Blog: How to Install Custom PHP Extensions on Heroku


Community Events

Don't see your event here?
Let us know!


language example voicesoftheelephpant api php7 security series video community version library framework laravel5 introduction interview opinion podcast release laravel extension

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework