Hot answers tagged

2

# Use PHP5.4 as default # Changed PHP handler from application/x-httpd-php54 to application/x-httpd-phpbeta on Thu Dec 17 16:50:26 MST 2015. AddHandler application/x-httpd-phpbeta .php # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / # Insert redirect based rewrites here. # Example: RewriteRule ^redirectme$ ...


2

and I want my link to be: http://example.com/shaandaar/kinna_sona.html shaandaar and kinna_sona are the slugs in my database. What should I write in my .htaccess file? This is the best way: RewriteEngine On RewriteRule ^([^/]+)/([^/]+)\.html$ /video_in.php?firstslug=$1&secondslug=$2 [L] In the RewriteRule, the ^ starts the matching. This: ...


2

You can have clean URLs with the following step. Install the wiki into http://localhost/w and NOT into http://localhost/wiki then Modify the following in LocalSettings.php after you have set it up: $wgArticlePath = "/wiki/$1"; In the ROOT directory place the following .htaccess file: RewriteEngine on ## uncomment this rule if you want to redirect to ...


1

The important thing is to place your external redirects before the WordPress internal rewrites (as Mike suggests in his answer). The WordPress rewrites are a "catch all" and rewrite everything. So if you place any rewrites/redirects after the WordPress stuff they will simply be ignored. RewriteCond %{HTTP_HOST} ^www\.example\.com$ RewriteRule ^/?$ ...


1

For the HTML files, you can't have it both ways. The only way for Varnish to always show HTML files if they've changed would be to check every time (=cache miss), at which point you've not gained anything by using it. If your site changes very frequently, setting a short cache time like you have is probably the best you can do (although 3 seconds might be a ...



Only top voted, non community-wiki answers of a minimum length are eligible