Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Here's how I did it.</p> <ol> <li>Edit your Windows Host file - C:\Windows\System32\drivers\etc\hosts</li> <li>Edit the Apache vhosts file - Drive-Letter:\xampp\apache\conf\extra\httpd-vhosts.conf</li> <li>Add an htaccess file to the laravel/public folder (if its not already there)</li> <li>Restart Xampp apache server</li> </ol> <p>Windows can be a real PITA when trying to edit the Hosts file because of the User Account Control. Since I work on all kinds of small hobby projects, I have to edit this file all the time so this is what I do.</p> <ul> <li>Install PSPad. It loads really fast and you can bookmark files for easy loading/editing. Sublime Text also works well if you load the two files I mentioned above and save the workspace as a new project.</li> <li>Right-click on the PSPad (or other editor) program shortcut and choose 'Run as Administrator'. You cannot save changes to the Hosts file unless you do this.</li> <li>Open the Windows Host file in the editor. This file does not have a file extension, so you have to choose "All Files" in the File Open dialog to even see the file.</li> <li><p>At the bottom of the file, add this:</p> <pre><code>127.0.0.1 laravel.dev </code></pre> <p>This tells Windows to point the web browser to localhost whenever you enter laravel.dev in the browser's address bar.</p></li> <li>Save the file.</li> <li>Open the xampp Apache httpd-vhosts.conf file.</li> <li><p>At the bottom of the file, add this: (I am assuming xampp is installed at the root of the D: drive)</p> <pre><code>&lt;VirtualHost *:80&gt; ServerName laravel.dev DocumentRoot "D:/xampp/htdocs/laravel/public" &lt;Directory "D:/xampp/htdocs/laravel/public"&gt; &lt;/Directory&gt; &lt;/VirtualHost&gt; </code></pre></li> <li><p>Add an htaccess file to your laravel/public folder (if its not already there). I think the default htaccess file that comes with L4 looks like this:</p> <pre><code>Options -MultiViews RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^ index.php [L] </code></pre></li> <li>Restart your xampp apache server.</li> <li>Open a web browser and type in the address bar - <code>http://laravel.dev</code></li> <li>That will take you to the index.php file in the "public" folder.</li> <li>To get to the About page, I think the address would be <code>http://laravel.dev/about</code></li> </ul>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload