Skip to content

MC-RhettW/open

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Open

Opens a file or URL in PHP, in a cross-platform way. This is a PHP port of node-open.

Installation

$ composer require florianv/open

Usage

Utility

Use the open() method to open a file or URL using the default or a specific app

use Open\Open;

Open::open('picture.jpg');

// It will use the default browser
Open::open('http://google.com');

// It will try to use Chrome
Open::open('http://google.com', 'chrome');

Command

Open Google using your default browser

$ php bin/open http://google.com

Open Google using the specified browser (firefox)

$ php bin/open http://google.com firefox

License

MIT

About

Opens a file or URL in PHP

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Shell 72.2%
  • PHP 27.8%