PHP code example of wdmg / lingua-detect

1. Go to this page and download the library: Download wdmg/lingua-detect 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/ */

    

wdmg / lingua-detect example snippets


    
        $text = 'Chicago has many historic places to visit. Keith found the Chicago Water Tower impressive as it is one
        of the few remaining landmarks to have survived the Great Chicago Fire of 1871.';
        $detector = new LinguaDetect();
        print $detector->process($text);