title: Target class [App\Http\Controllers\AdminTampilSekolahController] does not exist
body: <p>I am trying to do a basic CRUD app, but this is what I got.</p>
  
  <p>Can it be because the variable <code>$sekolah</code> can't read?</p>
  
  <p><strong>this is the source code</strong></p>
  
  <p><em>web.php</em></p>
  
  <pre><code>&lt;?php
  Route::get('/', function () {
      return view('index');
  });
  
  // Route::get('/event', function () {
  //  $namaevent = 'contoh event';
  //     return view('event',['namaevent' =&gt; $namaevent]);
  
  //route CRUD
  Route::get('/tampilsekolah','AdminTampilSekolahController@index');
  
  Route::get('/event','EventController@index');
  
  Route::get('/loker','LokerController@index');
  
  Route::get('/pencarian', function () {
      return view('pencarian');
  });
  
  Route::get('/listsekolah', function () {
      return view('listsekolah');
  });
  
  Route::get('/sekolaah', function () {
      return view('test');
  });
  </code></pre>
  
  <p><em>AdminTampilSekolahController.php</em></p>
  
  <pre><code>&lt;?php
  
  namespace App\Http\Controllers;
  
  use Illuminate\Support\Facades\DB;
  use Illuminate\Http\Request;
  use App\Http\Controllers;
  
  class InputSekolahController extends Controller
  {
      public function index()
      {
          // mengambil data dari table tb_sekolah
          $sekolah = DB::table('tb_sekolah')-&gt;get();
  
          // mengirim data sekolah ke view inputsekolah
          return view('admintampilsekolah',['sekolah' =&gt; $sekolah]);
  
      } 
  }
  </code></pre>
  
  <p>and the view <em>admintampilsekolah.blade.php</em></p>
  
  <pre><code>&lt;!doctype html&gt;
  &lt;html &gt;
    &lt;head&gt;
      &lt;!-- Required meta tags --&gt;
      &lt;meta charset="utf-8"&gt;
      &lt;meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"&gt;
  
      &lt;!-- Bootstrap CSS --&gt;
      &lt;link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous"&gt;
      &lt;link rel="stylesheet" type="text/css" href="/css/style.css"&gt;
  
      &lt;title&gt;List Sekolah (ADMIN)&lt;/title&gt;
    &lt;/head&gt;
    &lt;body&gt;
  &lt;!-- isi web  --&gt;
    &lt;div class="countainer"&gt;
      &lt;div class="card mx-auto" style="width: 85%; margin-top: 5%;"&gt;
        &lt;div class="card-header"&gt;
                  ...........
              &lt;/div&gt;
        &lt;div class="card-body"&gt;
          &lt;h5 class="card-title text-center"&gt;.........&lt;/h5&gt;
            &lt;div class="table-responsive-xl"&gt;
              &lt;table class="table table-bordered tabel table-striped"&gt;
                      &lt;thead class="thead-dark text-center"&gt;
                          &lt;tr&gt;
                          &lt;th scope="col"&gt;Kode Sekolah&lt;/th&gt;
                          &lt;th scope="col"&gt;Nama&lt;/th&gt;
                          &lt;th scope="col"&gt;Jenjang&lt;/th&gt;
                          &lt;th scope="col"&gt;Alamat&lt;/th&gt;
                          &lt;th scope="col"&gt;Kecamatan&lt;/th&gt;
                          &lt;th scope="col"&gt;Email&lt;/th&gt;
                          &lt;th scope="col"&gt;Notelp&lt;/th&gt;
                          &lt;th scope="col"&gt;Jumlah Guru&lt;/th&gt;
                          &lt;th scope="col"&gt;Jumlah Murid&lt;/th&gt;
                          &lt;th scope="col"&gt;Prestasi&lt;/th&gt;
                          &lt;th scope="col"&gt;Sarana&lt;/th&gt;
                          &lt;th scope="col"&gt;Akreditasi&lt;/th&gt;
                          &lt;th scope="col"&gt;Kurikulum&lt;/th&gt;
                          &lt;th width="10%" scope="col" colspan="2" &gt;Option&lt;/th&gt;
                          &lt;/tr&gt;
                      &lt;/thead&gt;
                      &lt;tbody class="text-center"&gt;
                      @foreach($sekolah as $s)
                              &lt;tr&gt;
                              &lt;td&gt;{{$s-&gt;Kode}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Nama}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Jenjang}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Alamat}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Kecamatan}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Email}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Notelp}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Jumlahguru}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Jumlahmurid}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Prestasi}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Sarana}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Akreditasi}}&gt;&lt;/td&gt;
                              &lt;td&gt;{{$s-&gt;Kurikulum}}&gt;&lt;/td&gt;
                              &lt;td&gt;
                                  &lt;a href="/tb_sekolah/edit/{{$s-&gt;Kode}}" class="btn btn-primary "&gt;EDIT&lt;/a&gt;
                              &lt;/td&gt;
                              &lt;td&gt;    
                                  &lt;a href="/tb_sekolah/hapus/{{$s-&gt;Kode}}" class="btn btn-danger "&gt;DELETE&lt;/a&gt;
                              &lt;/td&gt;
                              &lt;/tr&gt;
                          @endforeach
                      &lt;/tbody&gt;
                      &lt;/table&gt;        
            &lt;/div&gt;      
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  </code></pre>