PHP code example of mauricerenck / darkvisitors

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

    

mauricerenck / darkvisitors example snippets


'mauricerenck.dark-visitors.token' => 'YOUR TOKEN'

'mauricerenck.dark-visitors.aiTypes' => ['AI Assistant', 'AI Data Scraper', 'AI Search Crawler'],

'mauricerenck.dark-visitors.agents' => [
    [
        'userAgents' => ['Googlebot', 'Bingbot'],
        'disallow' => ['/admin'],
    ],
    [
        'userAgents' => ['Bingbot'],
        'allow' => ['/microsoft'],
    ],
],

[
    'userAgents' => ['*'],
    'disallow' => ['/kirby', '/site'],
];

'mauricerenck.dark-visitors.sitemaps' => [
    'Sitemap: https://your-site.tld/sitemap.xml',
    'Sitemap: https://your-site.tld/sitemap2.xml',
],

'mauricerenck.dark-visitors.analytics' => true,