PHP code example of omatech / editora-dbinterface

1. Go to this page and download the library: Download omatech/editora-dbinterface 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/ */

    

omatech / editora-dbinterface example snippets


$paginator=$extractor->getPaginator('/ca/news/', '?utm_source=xxx');

$paginator=[
'lastPage'=>false
,'firstPage'=>false
,'hasMorePages'=>true
,'nextPage'=>4
,'previousPage'=>2
,'onFirstPage'=>false
,'currentPage'=>3
'elements'=>[
	1=>['url'=>'/ca/news/1?utm_source=xxx'
		, 'isFirst'=>true
		, 'isLast'=>false
		, 'isCurrent=>false
	]
	2=>['url'=>'/ca/news/2?utm_source=xxx'
		, 'isFirst'=>false
		, 'isLast'=>false
		, 'isCurrent=>false
	]
	3=>['url'=>'/ca/news/3?utm_source=xxx'
		, 'isFirst'=>false
		, 'isLast'=>false
		, 'isCurrent=>true
	]
	4=>['url'=>'/ca/news/4?utm_source=xxx'
		, 'isFirst'=>false
		, 'isLast'=>false
		, 'isCurrent=>false
	]
	5=>['url'=>'/ca/news/5?utm_source=xxx'
		, 'isFirst'=>false
		, 'isLast'=>false
		, 'isCurrent=>false
	]
	6=>['url'=>'/ca/news/6?utm_source=xxx'
		, 'isFirst'=>false
		, 'isLast'=>true
		, 'isCurrent=>false
	]
]
];