在laravel刀片视图中调用非静态函数

I have a set of classes that are php files that contains functions which are not static (a set of files for image resizing that the client is determined on using them, they don't belong to any namespace, just old ordinary php files).

I need to call a method called imageResize from one of these files, what's the best approach for achieving this from a laravel 5.2 application?

Yes you can.

  1. Say your filename is my_all_functions.php. Copy this file to 'app/Http' directory.
  2. Edit composer.json file.
  3. Add these to your composer.json file

    "autoload": {
       "files": [
                "app/Http/my_all_functions.php"
              ]
    }
    
  4. Now you can access your custom functions from everywhere.

For a quick dirty job, use this:

{!! with(new MyClass())->someFunc($params) !!}

But consider using a service provider, and register you class with container if possible. That's the Laravel way.