PHP Classes

File: example_get.php

Recommend this page to a friend!
  Classes of Thomas Trautner   Better PHPinfo   example_get.php   Download  
File: example_get.php
Role: Example script
Content type: text/plain
Description: Example using get()
Class: Better PHPinfo
Get information about the current PHP request
Author: By
Last change: listing priority change
Date: 1 month ago
Size: 792 bytes
 

Contents

Class file image Download
<?php
/**
 * Example: Get Specific Configuration Values
 *
 * This example demonstrates how to retrieve specific configuration
 * values using the get() method.
 */

// Include the BetterPhpInfo class
require_once 'BetterPhpInfo.php';

// Create instance
$betterPhpInfo = new BetterPhpInfo();

echo
"<h2>Get Configuration Values Example</h2>";

// 5 simple get queries
echo "[memory_limit]: " . $betterPhpInfo->get('memory_limit') . "<br>";
echo
"[php_version]: " . $betterPhpInfo->get('php_version') . "<br>";
echo
"[upload_max_filesize]: " . $betterPhpInfo->get('upload_max_filesize') . "<br>";
echo
"[session_save_handler]: " . $betterPhpInfo->get('session_save_handler') . "<br>";
echo
"[opcache_enable]: " . $betterPhpInfo->get('opcache_enable') . "<br>";

?>