Storage folder has write permissions for webserver user? Think it's USER in IIS.
IIS7 Laravel 5
Hello everyone. I'm trying to get Laravel 5 working on IIS7. I have reviewed the following posts: https://laracasts.com/discuss/channels/general-discussion/does-anybody-use-iis-7-and-laravel-42
http://alvarotrigo.com/blog/installing-laravel-4-in-windows-7-with-iis7/
I know, call me crazy for using IIS, however in my work environment, we use "Windows Server" platform and I have another personal project that requires the use of IIS. For something small, it would be simple enough to use WAMP, but I can use that @ work...
I get a blank screen and nothing seems to happen... No error page or anything. Where there significant changes from 4 -> 5 that would cause this?
Laravel noob here, so please be gentle... ;)
@Only_tom et al
So, with special thanks to Only_tom and Alvaro Trigo @ http://alvarotrigo.com/blog/installing-laravel-4-in-windows-7-with-iis7/. I have been able to get IIS / PHP / Laravel to jive together... Here is the full rundown:
Ensure PHP and IIS are working together before proceeding any further. You should be using FastCGI with IIS and the Non-Thread Safe (NTS) versions of PHP(http://php.net/manual/en/install.windows.iis7.php). Quick sanity check with your phpinfo() file:
<?php
phpinfo();
?>
Verify you have made the following changes to your php.ini:
extension_dir = "ext"
cgi.force_redirect = 0
cgi.fix_pathinfo = 1
fastcgi.impersonate = 1
fastcgi.logging = 0
extension=php_mbstring.dll
extension=php_exif.dll ; Must be after mbstring as it depends on it
extension=php_mysql.dll
extension=php_mysqli.dll
extension=php_openssl.dll
extension=php_pdo_mysql.dll
date.timezone = "ENTER YOUR TIMEZONE HERE"
session.entropy_length = 32
Download and install composer for windows. (https://getcomposer.org/Composer-Setup.exe)
Open a command prompt with administrative access and restart IIS with the following command:
iisreset /restart
CD to the "C:\inetpub\wwwroot" folder and install laravel: ***This will take a few minutes.
C:\inetpub\wwwroot>composer create-project laravel/laravel --prefer-dist
Grant full control of the folder "C:\inetpub\wwwroot\laravel\storage" to IUSR ***This is very important!
Download URL Rewite from http://www.iis.net/downloads/microsoft/url-rewrite
Create the following file and save it as "Web.config" to the "C:\inetpub\wwwroot\laravel\public" folder. ***You will need administrative access to perform this task!
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="Rule 1" stopProcessing="true">
<match url="^(.*)/$" ignoreCase="false" />
<action type="Redirect" redirectType="Permanent" url="/{R:1}" />
</rule>
<rule name="Rule 2" stopProcessing="true">
<match url="^" ignoreCase="false" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" />
</conditions>
<action type="Rewrite" url="index.php" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
For good measure, restart IIS again. Open a command prompt with administrative access and type:
iisreset /restart
Visit http://localhost/laravel/public/index.php and hopefully you will see "Laravel 5"
I sure hope this helps anyone trying to install Laravel 5 on IIS.
Again, special thanks to Only_tom and Alvaro Trigo @ http://alvarotrigo.com/blog/installing-laravel-4-in-windows-7-with-iis7/ .
Please or to participate in this conversation.