PHP code example of codelytv / criteria-from-url

1. Go to this page and download the library: Download codelytv/criteria-from-url 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/ */

    

codelytv / criteria-from-url example snippets


$url = 'http://localhost:3000/api/users?filters[0][field]=name&filters[0][operator]=CONTAINS&filters[0][value]=Javi';

$converter = new CriteriaFromUrlConverter();

$criteria = $converter->toCriteria($url);