Invision Community 5: A video walkthrough creating a custom theme and homepage By Matt Thursday at 04:02 PM
AL Master Posted March 9, 2015 Posted March 9, 2015 Hello, I just cannot use URL Friendly...on Windows Server,, because i can't find .htaccess file to convert it to web Config Can someone give me the .htaccess, so I can convert it and enable the URL Friendly... Regards
xtech Posted March 9, 2015 Posted March 9, 2015 Well, i have extensively used windows server 2012 + IIS 8.5 for hosting IPB and i'll tell you something first: - IPB was not designed to be served in IIS. It's difficult to get the Furls working, IPS side there is no windows server support. Being so, if you are not proeficient in regex (i am not, too..) you will find very difficult to tune it to FURL. I have been trying for about one year, and i could do it. - You will run into encoding issues as windows server "prefers" to encode in Windows-1252 which is translatable to UTF8Mb4 (4 bytes to represent characters). Guess what? Till IPB 4.0, you cannot use UTF8MB4, as the IPS encoding method does not support it, and PHP in windows does not correctly receive the Locale information. So there are characters virtually impossible to use unless you make some deep editing of IPB source files (which i did to enable the € character, for example). As far as i know IPB 4.0 will support utf8MB4 but i have not tried it yet. - I do prefer windows for working, but i was able to migrate from Windows to linux in less than one week and i had never done it before nor used linux for hosting. My dedicated windows server had 32GB ram, SSD disk, 16 core CPU and i migrated to a much cheaper centOS alternative with 8GB Ram, SSD disk and 8 core CPU and i could see performance gains using NGINX. My board has about 27K users and almos a million posts, with lots of 3rd party apps. Having said this, i can give you the source for web.config i was using at my first attempt to get FURLs: <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <httpErrors errorMode="DetailedLocalOnly" existingResponse="Auto"> <remove statusCode="404" subStatusCode="-1" /> <error statusCode="404" prefixLanguageFilePath="%SystemDrive%\inetpub\custerr" path="404.htm" responseMode="File" /> </httpErrors> <rewrite> <rules> <rule name="Imported Rule 1" stopProcessing="true"> <match url="\.(jpeg|jpg|gif|png)$" /> <conditions logicalGrouping="MatchAll"> <add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" /> </conditions> <action type="Rewrite" url="/public/404.php" /> </rule> <rule name="Imported Rule 2" stopProcessing="true"> <match url="." ignoreCase="false" /> <conditions logicalGrouping="MatchAll"> <add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" /> <add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" negate="true" /> </conditions> <action type="Rewrite" url="/index.php" /> </rule> <rule name="WWWless" stopProcessing="true"> <match url="^(.*)$" /> <conditions> <add input="{HTTP_HOST}" pattern="^(www\.)(.*)$" /> </conditions> <action type="Redirect" url="http://forumusica.com{PATH_INFO}" /> </rule> <rule name="IP Canonicalization (IP Hit)" enabled="false" stopProcessing="true"> <match url="(.*)" /> <conditions> <add input="HTTP_HOST" pattern="144.76.117.172" /> </conditions> <action type="Redirect" url="http://forumusica.com" /> </rule> <rule name="RedirectUserFriendlyURL1" stopProcessing="true"> <match url="^index\.php$" /> <conditions> <add input="{REQUEST_METHOD}" pattern="^POST$" negate="true" /> <add input="{QUERY_STRING}" pattern="^([^=&]+)$" /> </conditions> <action type="Redirect" url="{C:1}" appendQueryString="false" /> </rule> <rule name="RewriteUserFriendlyURL1" stopProcessing="true"> <match url="^([^/]+)/?$" /> <conditions> <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" /> <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" /> </conditions> <action type="Rewrite" url="index.php?{R:1}" /> </rule> </rules> </rewrite> <httpRedirect enabled="false" httpResponseStatus="Permanent" /> <urlCompression doDynamicCompression="false" /> <caching> <profiles> <add extension=".css" policy="DontCache" kernelCachePolicy="CacheUntilChange" /> <add extension=".png" policy="DontCache" kernelCachePolicy="CacheUntilChange" /> <add extension=".jpg" policy="DontCache" kernelCachePolicy="CacheUntilChange" /> </profiles> </caching> </system.webServer> <system.web> <customErrors mode="Off" /> </system.web> </configuration> Do not forget to change the forumusica.com to your address The second way (more direct and you can even use the .htaccess file directly - at the cost of speed) is the use of the Helicon APE extension for IIS. Basically, it enables the use of the .htaccess for you site. I has a downside: it increases response time (despite Helicon saying it's fast). Nevertheless i ended up using it to obtain the best FURL and IPContent working.
Stuart Silvester Posted March 9, 2015 Posted March 9, 2015 You can import the htaccess rules into IIS Rewrite, the relevant rewrite information is in your ACP, search for mod_rewritehttps://help.webcontrolcenter.com/kb/a1487/iis7-url-rewrite-importing-iis-mod-rewrite-rules-apache.aspx
Andrew Anderson Posted June 14, 2015 Posted June 14, 2015 There is no "relevant rewrite information".
Recommended Posts
Archived
This topic is now archived and is closed to further replies.