title: How Can I Remove “public/index.php” in the URL Generated Laravel?
body: <p>I need to remove  <code>index.php</code> or <code>public/index.php</code> from the generated URL in Laravel; commonly path is <code>localhost/public/index.php/someWordForRoute</code>, It should be something like <code>localhost/someWordForRoute.</code></p>
  
  <p><strong>.htaccess</strong></p>
  
  <pre><code>&lt;IfModule mod_rewrite.c&gt;
  &lt;IfModule mod_negotiation.c&gt;
  Options -MultiViews
  &lt;/IfModule&gt;
  
  RewriteEngine On
  
  # Redirect Trailing Slashes.
  RewriteRule ^(.*)/$ /$1 [L,R=301]
  
  # Handle Front Controller.
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule ^ index.php[L]
  </code></pre>
  
  <p></p>
  
  <p><strong>app/config/app.php</strong></p>
  
  <pre><code>'url' =&gt; 'http://localhost',
  </code></pre>
  
  <p>How can I change that?</p>