xref: /unit/test/php/cwd/index.php (revision 2022:69607c6bb2b5)
11381St.nateldemoura@f5.com<?php
21381St.nateldemoura@f5.com
31381St.nateldemoura@f5.comif (isset($_GET['chdir']) && $_GET['chdir'] != "") {
41381St.nateldemoura@f5.com    if (!chdir($_GET['chdir'])) {
51381St.nateldemoura@f5.com        echo "failure to chdir(" . $_GET['chdir'] . ")\n";
61381St.nateldemoura@f5.com        exit;
71381St.nateldemoura@f5.com    }
81381St.nateldemoura@f5.com}
91381St.nateldemoura@f5.com
101381St.nateldemoura@f5.com$opcache = -1;
111381St.nateldemoura@f5.com
121381St.nateldemoura@f5.comif (function_exists('opcache_get_status')) {
131507Szelenkov@nginx.com    $status = opcache_get_status();
14*2022Szelenkov@nginx.com    $opcache = $status['opcache_enabled'] ? '1' : '0';
151381St.nateldemoura@f5.com}
161381St.nateldemoura@f5.com
171381St.nateldemoura@f5.comheader('X-OPcache: ' . $opcache);
181381St.nateldemoura@f5.com
191381St.nateldemoura@f5.comprint(getcwd());
201381St.nateldemoura@f5.com?>
21