Download the PHP package navisborealis/wonderwords-php without Composer
On this page you can find all versions of the php package navisborealis/wonderwords-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download navisborealis/wonderwords-php
More information about navisborealis/wonderwords-php
Files in navisborealis/wonderwords-php
Package wonderwords-php
Short Description Generate random words and sentences with ease in PHP.
License MIT
Homepage https://github.com/navisborealis/wonderwords-php
Informations about the package wonderwords-php
Wonderwords PHP
Generate random words, phrases and sentences with ease in PHP.
Installation
To install the package, run the following command:
Usage
With this library you can generate:
- words - adjectives, nouns or verbs
- phrases - 1+ adjective and 1+ noun, like
Blushing Inspection
- sentences - this feature is still in development
Phrases
Basic structure of the phrase is adjective noun
. You can change:
- string separator, default
- number of adjectives and nouns, default
1
, - function used to modify the letters case, default
ucwords()
.
To use your own list of words see Changing default word list.
Generic, two word, space separated phrase
Custom separator
Different number of adjectives and nouns
Custom function to change letters casing
Words
Generating words
From each category (Adjective
, Noun
, Verb
) you can generate a single word:
or an array of words:
Changing default word list
For each word category (Adjective
, Noun
, Verb
) you can change the default word list:
also, you can reset word list to its defaults:
Sentences
In development...
Credits
Wonderwords PHP is based on wonderwordsmodule
python module and has been made possible thanks to the following works:
wonderwordsmodule
for python under the MIT Licenseprofanitylist.txt
from RobertJGabriel/Google-profanity-words under the Apache-2.0 license- PhraseGenerator under the MIT License
- word-generator under the MIT license