Creates nice sentences
Creates nice sentences.
Use Composer to install by running
$ composer require bitandblack/sentence-construction and
$ composer update.
Just call the method like that:
<?php use BitAndBlack\SentenceConstruction; $fruits = [ 'Apples', 'Bananas', 'Pears' ]; $sentence = SentenceConstruction::getImplodedSentence(', ', ' and ', $fruits); var_dump('I like '.$sentence);
This will dump
I like Apples, Bananas and Pears.
If you have any questions feel free to contact us under