php - file_exist function won't work -


I have a function that checks that the mobile image is present, and if so, it will return the truth, no difference What I can do is that I can not work this function properly.

  public function mobileImageExist ($ image) {$ file = "images / $ image"; If (file_exists ($ file)) is true; return false; }   

I have also tried

  public function mobile imageexist ($ image) {$ file = dirname (__ file __). "/ Images / $ image"; If (file_exists ($ file)) is true; return false; } The $ image parameter that the function is being passed is just the name of the image eg: banner_mobile.jpg   

Comments

Popular posts from this blog

How can I add a seperate action listener to all 14 of my buttons at once that can determine player turn?(java) -

Simple file compression in C -

php - Sorting an multidimension array using usort fails -