PHP code example of badcow / phrase-generator

1. Go to this page and download the library: Download badcow/phrase-generator 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/ */

    

badcow / phrase-generator example snippets




adcow\PhraseGenerator\PhraseGenerator;

echo PhraseGenerator::generate(); // 1 adjective and 1 noun




adcow\PhraseGenerator\PhraseGenerator;

echo PhraseGenerator::generate(2, 1); // 2 adjectives and 1 noun