Skip to content

Instantly share code, notes, and snippets.

@felipelavinz
Created October 4, 2017 19:10
Show Gist options
  • Save felipelavinz/5406f1a82a3b59ac4433a7f424687873 to your computer and use it in GitHub Desktop.
Save felipelavinz/5406f1a82a3b59ac4433a7f424687873 to your computer and use it in GitHub Desktop.
$HTTP["host"] =~ "www.domain.com|domain.com" {
# Configuraciónes Basicas
server.document-root = "/var/www/htdocs"
server.error-handler-404 = "/index.php?error=404"
$HTTP["url"] =~ "^/xmlrpc.php" {
url.access-deny = ( "" )
server.error-handler-404 = "/403.php"
}
# Rewrite
url.rewrite-final = (
"^/([_0-9a-zA-Z-]+/)?(wp-json.*)" => "/index.php/$2",
"^/index\.php$" => "/$0",
"^/([_0-9a-zA-Z-]+/)?wp-admin$" => "/$1wp-admin/",
"^/([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*)" => "/$2",
"^/([_0-9a-zA-Z-]+/)?(.*\.php)" => "/$2",
"^/(.*)/?$" => "/index.php"
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment