Installing Package in Laravel VIA Composer -


i using laravel 4 project, download package turns youtube/vimeo urls embed, required package in composer , run composer update.

however trying use package keep getting error:

class 'embed' not found  

the code in helpers.php file:

function embed_video($url, $width = 0, $height = 0) {     $embed = embed::make($url)->parseurl();      if ($embed) {         // set width of embed.         if ($width > 0)         {             $embed->setattribute(['width' => $width]);         }          // set height of embed.         if ($height > 0)         {             $embed->setattribute(['height' => $height]);         }          return $embed->gethtml();     }  } 

i call function in view.
link package: cohensive


Comments

Popular posts from this blog

java - Ebean enhancement ignores a model -

ubuntu - How to disable Kernel Module Signing in linux -

SQL php on different pages to Insert (mysqli) -