Last active
June 12, 2017 05:15
-
-
Save noogen/3bffc24e1001e3e6ea8478c866efd8e6 to your computer and use it in GitHub Desktop.
Concrete5.7+ in subfolder with hidden subfolder
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# BEGIN Concrete5 rewrite | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
RewriteCond %{REQUEST_URI} !^/c5/ | |
# exclude other sub-directories if necessary | |
RewriteCond %{REQUEST_URI} !^/dev/ | |
RewriteCond %{REQUEST_URI} !^/dev2/ | |
# exclude ssl stuff | |
RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$ | |
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$ | |
RewriteCond %{REQUEST_URI} !^/\.well-known/acme-challenge/[0-9a-zA-Z_-]+$ | |
RewriteRule ^(.*)$ c5/$1 [L] | |
</IfModule> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$myappfolder = 'c5/'; | |
$_SERVER['PHP_SELF'] = str_replace($myappfolder, '', $_SERVER['PHP_SELF']); | |
$_SERVER['SCRIPT_NAME'] = str_replace($myappfolder, '', $_SERVER['SCRIPT_NAME']); | |
require 'concrete/dispatcher.php'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment