Demos para ilustrar uso de los utilitarios miframe_server()
y miframe_autoload()
de la librería miFrame\Commons
Variables usadas para crear el arreglo de muestra:
Importante: Algunos valores se han ocultado por seguridad, pero son visibles para consultas desde "localhost".
$path_dummy | => | '../path/to/other/script/ignora/..' |
$script | => | '[SCRIPT_FILENAME]' |
Arreglo de muestra:
miframe_server()->startAt() | => | 1730831873.9335 |
miframe_server()->startAt('Y/m/d H:i:s') | => | '2024/11/05 13:37:53' |
miframe_server()->checkPoint() [Inicio] | => | 0.0603508 |
miframe_server()->purgeURLPath($path_dummy) | => | '/path/to/other/script' |
miframe_server()->purgeFilename($path_dummy) | => | '/path/to/other/script' |
miframe_server()->get('REQUEST_METHOD') | => | 'GET' |
miframe_server()->client() | => | '3.141.37.212' |
miframe_server()->isWeb() | => | true |
miframe_server()->useHTTPSecure() | => | true |
miframe_server()->isLocalhost() | => | false |
miframe_server()->software() | => | '[Restringido]' |
miframe_server()->browser() | => | '[Restringido]' |
miframe_server()->rawInput() | => | '' |
miframe_server()->name() | => | '[Restringido]' |
miframe_server()->ip() | => | '45.56.67.215' |
miframe_server()->path() | => | '/software/miframe-commons/demo/support/demo-server.php' |
miframe_server()->pathInfo() | => | '' |
miframe_server()->host() | => | 'https://lekosdev.com/' |
miframe_server()->host(true) | => | 'https://lekosdev.com/' |
miframe_server()->self() | => | '/software/miframe-commons/demo/support/demo-server.php' |
miframe_server()->relativePath() | => | '/software/miframe-commons/demo/support/' |
miframe_server()->relativePath($path_dummy) | => | '/software/miframe-commons/demo/support/path/to/other/script' |
miframe_server()->documentRoot() | => | '[DOCUMENT_ROOT]/' |
miframe_server()->documentRoot($path_dummy) | => | '[DOCUMENT_ROOT]/path/to/other/script' |
miframe_server()->documentRootSpace() | => | 103968862208 |
miframe_server()->script() | => | '[SCRIPT_FILENAME]' |
miframe_server()->scriptDirectory() | => | '[DOCUMENT_ROOT]/software/miframe-commons/demo/support/' |
miframe_server()->scriptDirectory($path_dummy) | => | '[DOCUMENT_ROOT]/software/miframe-commons/demo/support/path/to/other/script' |
miframe_server()->removeDocumentRoot($script) | => | 'software/miframe-commons/demo/support/demo-server.php' |
miframe_server()->removeDocumentRoot($path_dummy) | => | false |
miframe_server()->tempDir() | => | '[TEMP_DIR]/' |
miframe_server()->tempDirSpace() | => | 103968862208 |
miframe_server()->hasAccessTo($path_dummy) | => | false |
miframe_server()->hasAccessTo($script) | => | true |
miframe_server()->mkdir($path_dummy) | => | false |
miframe_server()->createTempSubdir($path_dummy) | => | '[TEMP_DIR]/path/to/other/script' |
miframe_server()->executionTime() | => | 0.06572699546814 |
miframe_server()->checkPoint() [Fin] | => | 0.005397 |
Respecto al uso de la librería autoload.php
, estas son las Clases evaluadas durante esta presentación:
miFrame\Commons\Core\ServerData | => | '[DOCUMENT_ROOT]/software/miframe-commons/src/miframe/commons/core/ServerData.php' |
miFrame\Commons\Traits\GetLocalData | => | '[DOCUMENT_ROOT]/software/miframe-commons/src/miframe/commons/traits/GetLocalData.php' |
Y estos son los namespaces registrados:
miframe\commons\* | => | '[DOCUMENT_ROOT]/software/miframe-commons/src/miframe/commons/*.php' |