dev-master
9999999-devA simple PHP library package to append JSON entries into a pre-existing JSON file
dbad
The Requires
- php >=5.4
The Development Requires
by Dhiraj Timalsina
json composer append
Wallogit.com
2017 © Pedro Peláez
A simple PHP library package to append JSON entries into a pre-existing JSON file
If you are trying to append a JSON entry into a pre-existing JSON file, you can use this library to add/append additional entries to a JSON file format. This package also supports a separate function to ignore pre-existing JSON entries., (*1)
composer require dhiraj1site/jsonappend, (*2)
There are basically two major functions used in the JSONAppend class., (*3)
This function requires two parameters. The first parameter will be the source JSON file you need to append into. The second parameter will be an array with key/value pair which you require to append into the source JSON file., (*4)
@param1 - .json file
@param2 - array $appenditems, (*5)
This function is similar to appendJSON. Except this ignores duplicate JSON entires. Parameters are the same as above, (*6)
use JSONAppend;
JSONAppend::appendUniqueJSON('services.json', array($items));
A simple PHP library package to append JSON entries into a pre-existing JSON file
dbad
json composer append