php - Input::file() returns nothing -


i trying upload image using laravel frame work facing difficulty problem $file=input::file(); returns nothing , after when write $filename = $file->getclientoriginalname(); error call member function getclientoriginalname() on non-object please me here html code

<form action="enter-input" method="get" enctype="multipart/form-data"> <input    name='image' style="width:194px;"type='file' class='form-control'> <input type="submit"  class="btn btn-primary" value="submit"> </form> 

here controller code

$file= input::file('image');     $filename = $file->getclientoriginalname(); 

the first line returns nothing , second line shows error call member function getclientoriginalname() on non-object me guys stuck in problem , new laravel.

change method="get" method="post".


Comments

Popular posts from this blog

java - Custom OutputStreamAppender not run: LOGBACK: No context given for <MYAPPENDER> -

java - UML - How would you draw a try catch in a sequence diagram? -

c++ - No viable overloaded operator for references a map -