PHP code example of quorum / dot-notation

1. Go to this page and download the library: Download quorum/dot-notation 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/ */

    

quorum / dot-notation example snippets




use Quorum\DotNotation\DotNotationParser;

oo',
	'foo.bar',
	'spaces are allowed'                  => 'foo bar.baz',
	'dots are accepted in quotes'         => '"foo.bar".baz',
	'quotes are escaped with backslashes' => '"foo\"bar\"".baz',
];

foreach( $tests as $descr => $test ) {
	echo sprintf("Parsing '%s'%s\n",
		$test,
		is_numeric($descr) ? '' : ' - ' . $descr);

	$parts = $parser->parse($test);

	echo sprintf("[ %s ]\n", implode(", ", array_map(
		function ( $a ) { return var_export($a, true); },
		$parts)));
	echo "\n";
}


function parse(string $path) : array