This is my Controller:
public function create(){
$categories =DB::select('select Code from ItemCategory');
return view('item')->with('ItemCategory', $categories);
My View file:
<div class="form-group">
{!! Form::label('Link Category') !!}<br />
{!! Form::select('categories',
(['0' => 'Select a Category'] + $categories),
null,
['class' => 'form-control']) !!}
</div>
But when I run this , I get following error
InvalidArgumentException in FileViewFinder.php line 137: View [item] not found.
PS:
My database table:
+----------------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+----------------+-------------+------+-----+---------+-------+
| ID | int(11) | NO | PRI | NULL | |
| Code | varchar(45) | NO | | NULL | |
| ItemCategotyID | int(11) | NO | | NULL | |
| ItemLevelID | int(11) | NO | | NULL | |
| isActive | varchar(45) | YES | | NULL | |
+----------------+-------------+------+-----+---------+-------+
I have tried this example. What is the mistake here? How to get values for a drop down using MySQL table?

/resources/views, then the view need to be called with"subdir.viewname". If this is not the case, then the possible issue is with the namespace.