title: Laravel 4 upload 1 image and save as multiple (3)
body: <p>I'm trying to make an image upload script with laravel 4. (using Resource Controller) and i'm using the package Intervention Image.</p>
  
  <p>And what i want is: when uploading an image to save it as 3 different images (different sizes).</p>
  
  <p>for example:</p>
  
  <p>1-foo-original.jpg</p>
  
  <p>1-foo-thumbnail.jpg</p>
  
  <p>1-foo-resized.jpg</p>
  
  <p>This is what i got so far.. it's not working or anything, but this was as far as i could get with it.</p>
  
  <pre><code>if(Input::hasFile('image')) {
       $file             = Input::file('image');
       $fileName         = $file-&gt;getClientOriginalName();
       $fileExtension    = $file-&gt;getClientOriginalExtension();
       $type = ????;
  
       $newFileName = '1' . '-' . $fileName . '-' . $type . $fileExtension;
  
       $img =  Image::make('public/assets/'.$newFileName)-&gt;resize(300, null, true);
       $img-&gt;save();
  }
  </code></pre>
  
  <p>Hopefully someone can help me out, thanks!</p>