title: How to convert the image title to a slug and save it to the Database? Laravel
body: <p>A user can upload an <code>image</code> and I want to catch the provided <code>$request</code> image title and convert it to a <code>slug</code> and save it to the <code>Database</code></p>
  
  <p>UploadScreenShotController@upload:</p>
  
  <pre><code>public function upload(Request $request)
  {
      if (!auth()-&gt;check()) return $this-&gt;with('error', 'Session has ended. Please refresh the page and try again.');
  
      $request-&gt;validate([
          'image' =&gt; 'required|image|mimes:jpeg,png,jpg,gif,svg|max:2048',
      ]);
  
      $image = $request-&gt;image;
      $filename = $image-&gt;getClientOriginalName();
  
      $request-&gt;image-&gt;move(public_path('images/tcpa/screenshots'), $filename);
  
      return back()
          -&gt;with('success', 'You have successfully uploaded an image.')
          -&gt;with('image', $filename);
  }
  </code></pre>
  
  <p>My form:</p>
  
  <pre><code>        {!! Form::open(['method' =&gt; 'POST', 'files' =&gt; 'true', 'route' =&gt; ['admin.sms.tcpa-upload-screenshot']])!!}
              {!! Form::file('image') !!}
              {!! Form::submit('Upload File') !!}
          {!! Form::close() !!}
  </code></pre>
  
  <p>This <code>function</code> gets the <code>image</code> name, but it doesn't convert it to a <code>slug</code> and it doesn't save in the <code>Database</code>.</p>
  
  <p>How to convert the <code>image</code> title to a <code>slug</code> and save it to the <code>Database</code>?</p>