Is it "Includes" with a capital I, or "includes" with a small i? Error message shows capital I (/home/forge/mysite.com/app/Includes/timezones.php), you show using lower case (mysite/app/includes/timezones.php)
Failed opening required file
I've been working on homestead and everything is running fine. I deployed my app via Forge and am getting this error when I go to my registration screen which I added a timezone field. This is Laravel 5.6 (Spark) Here's the error:
[2018-10-17 23:00:02] production.ERROR: Illuminate\View\Engines\PhpEngine::main(): Failed opening required '/home/forge/mysite.com/app/Includes/timezones.php' (include_path='.:/usr/share/php') {"exception":"[object] (Symfony\Component\Debug\Exception\FatalErrorException(code: 64): Illuminate\View\Engines\PhpEngine::main(): Failed opening required '/home/forge/mysite.com/app/Includes/timezones.php' (include_path='.:/usr/share/php') at /home/forge/mysite.com/storage/framework/views/9f17b86cb5c3c5b4a210625acadf859908ee2e84.php:64)
[stacktrace]
#0 {main}
"}
The file it cannot open is located here: mysite/app/includes/timezones.php
Here's the code I use to include the timezone field to the registration form. Am I including the file wrong? Again this works for my other project that is running Laravel 5.4.
<!-- Timezone -->
<?php require(app_path().'/Includes/timezones.php'); ?>
<div class="form-group row">
<label class="col-md-4 col-form-label text-md-right">{{__('Timezone')}}</label>
<div class="col-md-6">
<select class="form-control" name="timezone" v-model="registerForm.timezone">
@foreach ($timezones as $formTimezone => $utc)
<option value="{{ $formTimezone }}">{!! $utc !!}</option>
@endforeach
</select>
<span class="invalid-feedback" v-show="registerForm.errors.has('timezone')">
@{{ registerForm.errors.get('timezone') }}
</span>
</div>
</div>
I have another project in which I did the same thing adding a timezone field to the registration screen and it works just fine.
Any ideas?
Please or to participate in this conversation.