PHP code example of mapsight / pulp

1. Go to this page and download the library: Download mapsight/pulp library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

mapsight / pulp example snippets


->pipe(Pulp::fileSwitch(
	array(
		'*.php' => function($p) {
			//...
		},
		'*.js' => function($p) {
			//...
		}
	),
	function($p) {
		// default
	}
))

use \OpenMapsight\Pulp;

Pulp::start()
	->pipe(Pulp::src('mydir/*.txt'))
	->pipe(Pulp::map(function($f) {
		$f->content .= 'fo';
		return $f;
	}))
	->pipe(Pulp::dest('myotherdir'))
	->run();