A free open source IT asset/license management system
Added phpinfo page if debugging is enabled
snipec2927c4a2e12
diff --git a/app/Http/Controllers/SettingsController.php b/app/Http/Controllers/SettingsController.phpindex 0bc33037c1..f930457edb 100755--- a/app/Http/Controllers/SettingsController.php+++ b/app/Http/Controllers/SettingsController.php@@ -687,6 +687,18 @@ class SettingsController extends Controller}+ /**+ * Return a form to allow a super admin to update settings.+ *+ * @author [A. Gianotto] [<[email protected]>]+ * @since [v4.0]+ * @return View+ */+ public function getPhpInfo()+ {+ return view('settings.phpinfo');+ }+/*** Return a form to allow a super admin to update settings.diff --git a/resources/views/settings/index.blade.php b/resources/views/settings/index.blade.phpindex afcc8def11..3d080901c0 100755--- a/resources/views/settings/index.blade.php+++ b/resources/views/settings/index.blade.php@@ -163,7 +163,18 @@</div></div>-+ @if (config('app.debug')=== true)+ <div class="col-md-4 col-lg-3 col-sm-6 col-xl-1">+ <div class="box box-default">+ <div class="box-body text-center">+ <a href="{{ route('settings.phpinfo.index') }}" class="btn btn-lg btn-white"><i class="fa fa-server fa-3x"></i></a>+ <br>+ PHP+ <p class="help-block">PHP System Info</p>+ </div>+ </div>+ </div>+ @endif<div class="col-md-4 col-lg-3 col-sm-6 col-xl-1"><div class="box box-danger">@@ -176,12 +187,6 @@</div></div>------</div>@@ -229,6 +234,7 @@</div><!--/row-->+@stopdiff --git a/resources/views/settings/phpinfo.blade.php b/resources/views/settings/phpinfo.blade.phpnew file mode 100644index 0000000000..4513d2626c--- /dev/null+++ b/resources/views/settings/phpinfo.blade.php@@ -0,0 +1,31 @@+@extends('layouts/default')++{{-- Page title --}}+@section('title')+ PHP Info+ @parent+@stop++@section('header_right')+ <a href="{{ route('settings.index') }}" class="btn btn-default"> {{ trans('general.back') }}</a>+@stop+++{{-- Page content --}}+@section('content')+ @if (config('app.debug')=== true)+ <div class="row">+ <div class="col-md-12">+ <?php phpinfo(); ?>+ </div> <!-- /.col-md-12-->+ </div> <!-- /.row-->++ @else+ <div class="col-md-12">+ <div class="alert alert-danger">+ This information is only available when debug is enabled.+ </div>+ @endif+++@stopdiff --git a/routes/web.php b/routes/web.phpindex e476249d9f..983d2fb133 100644--- a/routes/web.php+++ b/routes/web.php@@ -140,6 +140,7 @@ Route::group([ 'prefix' => 'admin','middleware' => ['authorize:superuser']], funRoute::get('ldap', ['as' => 'settings.ldap.index','uses' => 'SettingsController@getLdapSettings' ]);Route::post('ldap', ['as' => 'settings.ldap.save','uses' => 'SettingsController@postLdapSettings' ]);+ Route::get('phpinfo', ['as' => 'settings.phpinfo.index','uses' => 'SettingsController@getPhpInfo' ]);Route::get('oauth', [ 'as' => 'settings.oauth.index', 'uses' => 'SettingsController@api' ]);