PHP code example of helionogueir / changedirective

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

    

helionogueir / changedirective example snippets


use helionogueir\changedirective\cgi\Debug;
(new Debug())->set(Debug::DEVELOPER);

use helionogueir\changedirective\cgi\Debug;
(new Debug())->set(Debug::HOMOLOGATION);

use helionogueir\changedirective\cgi\Debug;
(new Debug())->set(Debug::PRODUCTION);

use helionogueir\changedirective\cgi\Locale;
(new Locale())->set("en-US", "utf-8")

use helionogueir\changedirective\cgi\Session;
(new Session())
  // Optional: Define session lifetime
  ->setMaxLifetime(3600)
  // Optional: Define session path storage files
  ->setPath(sys_get_temp_dir())
  // Start sesson
  ->start());

use helionogueir\changedirective\cgi\Timezone;
(new Timezone())->set("Europe/London");