3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace App\Http\Controllers\User; use Auth; use File; use App\User; use App\City; use App\Image; use App\Scope; use App\Skill; use App\CandidateSkills; use App\Reference; use App\Attribute; use App\Candidate; use App\Speciality; use App\Helpers\Helper; use Illuminate\Http\Request; use App\Rules\CheckCity; use App\Rules\CheckScope; use App\Rules\CheckSalary; use App\Rules\IsEmptyString; use App\Rules\CheckSpeciality; use Illuminate\Validation\Rule; use App\Http\Controllers\Controller; use App\Rules\CheckUniversityFinishYear; use Illuminate\Support\Facades\Validator; class ProfileController extends Controller { public function index($nickname) { return view('user.profile.resume'); } public function resume() { $user = User::find(auth()->user()->id); $data = [ 'user' => $user, ]; return view('user.profile.resume', $data); } public function edit() { $user = User::findOrfail(Auth::id()); $candidate = $user->candidate; $specialities = Speciality::all(); $skills = Skill::all(); $data = [ 'user' => $user, 'candidate' => $candidate, 'specialities' => $specialities, 'userSpecialityId' => 1, 'cities' => City::all(), 'skills' => $skills ]; return view('user.profile.edit', $data); } public function update(Request $request) { $user = User::findOrfail(Auth::id()); if(isset($request->about)) { $this->validate($request, [ 'about' => 'required|min:50' ]); $candidate->about = $request->about; $candidate->save(); } return "Success"; } }
Output for 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.4, 8.3.6
Fatal error: Uncaught Error: Class "App\Http\Controllers\Controller" not found in /in/faM6F:29 Stack trace: #0 {main} thrown in /in/faM6F on line 29
Process exited with code 255.
Output for 8.3.5
Warning: PHP Startup: Unable to load dynamic library 'sodium.so' (tried: /usr/lib/php/8.3.5/modules/sodium.so (libsodium.so.23: cannot open shared object file: No such file or directory), /usr/lib/php/8.3.5/modules/sodium.so.so (/usr/lib/php/8.3.5/modules/sodium.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0 Fatal error: Uncaught Error: Class "App\Http\Controllers\Controller" not found in /in/faM6F:29 Stack trace: #0 {main} thrown in /in/faM6F on line 29
Process exited with code 255.
Output for 7.3.16 - 7.3.33, 7.4.0 - 7.4.33
Fatal error: Uncaught Error: Class 'App\Http\Controllers\Controller' not found in /in/faM6F:29 Stack trace: #0 {main} thrown in /in/faM6F on line 29
Process exited with code 255.
Output for 7.1.0 - 7.1.23, 7.2.0 - 7.2.33
Fatal error: Class 'App\Http\Controllers\Controller' not found in /in/faM6F on line 29
Process exited with code 255.
Output for 5.6.38
Fatal error: Class 'App\Http\Controllers\Controller' not found in /in/faM6F on line 30
Process exited with code 255.

preferences:
177.28 ms | 405 KiB | 174 Q