This file contains 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
{# | |
# Example of building a slideshow in Craft from adjacent matrix blocks. | |
# | |
# This is a technique for getting around the problem of not being able to nest | |
# matrix fields. Say you're using a matrix field for your 'article-body' | |
# that has rich-text fields, headings, photos with captions, and slideshows | |
# all mixed together as different blocks. The slideshow is created by just placing | |
# single slideshow images (with captions) next to each other in the matrix. | |
# | |
# For example: |
This file contains 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
# Force training slash in URL | |
<IfModule mod_rewrite.c> | |
RewriteCond %{REQUEST_METHOD} !=POST | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteRule ^(.*)([^/])$ http://%{HTTP_HOST}/$1$2/ [L,R=301] | |
</IfModule> |
This file contains 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
#Block hotlinking | |
RewriteCond %{HTTP_REFERER} !^$ | |
RewriteCond %{HTTP_REFERER} !^http(s)?://(.+\.)?mydomain.com [NC] | |
RewriteRule \.(jpg|jpeg|png|gif|css|js)$ - [NC,F,L] | |
#Block comment spammers, bad bots and some proxies | |
RewriteCond %{REMOTE_HOST} 24.117.121.113 [OR] | |
RewriteCond %{REMOTE_HOST} ^211.138.198.* [OR] | |
RewriteCond %{REMOTE_HOST} 216.246.60.183 [OR] | |
RewriteCond %{REMOTE_HOST} 203.94.229.227 [OR] |
This file contains 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 | |
/** | |
* Custom configuration bootsrtap file for ExpressionEngine | |
* | |
* Place config.php in your site root | |
* Add require(realpath(dirname(__FILE__) . '/../../config_bootstrap.php')); to the bottom of system/expressionengine/config/config.php | |
* Add require(realpath(dirname(__FILE__) . '/../../config_bootstrap.php')); to the bottom of system/expressionengine/config/database.php | |
* If you have moved your site root you'll need to update the require_once path | |
* |
This file contains 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 | |
/** | |
* Custom configuration bootsrtap file for ExpressionEngine | |
* | |
* Place config.php in your site root | |
* Add require(realpath(dirname(__FILE__) . '/../../config_bootstrap.php')); to the bottom of system/expressionengine/config/config.php | |
* Add require(realpath(dirname(__FILE__) . '/../../config_bootstrap.php')); to the bottom of system/expressionengine/config/database.php | |
* If you have moved your site root you'll need to update the require_once path | |
* |