This is a simple technique which should work on ALL hosts to allow ExpressionEngine to handle URLs without index.php in them. Hopefully EllisLab will add this as a built-in option soon.
IJR
#!/bin/bash | |
# Execute via: ./set-project-perms.sh PROJECT_NAME | |
# The paradigm is the entire project dir is owned by $CHOWN_USER with the group set to $CHOWN_GROUP | |
# $CHOWN_USER is an admin or user account that is used to edit files/templates, etc. | |
# $CHOWN_GROUP is the group of the webserver (e.g.: 'apache', 'nginx', 'httpd', etc.) | |
# The project dir permissions are set to 755 (-rwxr-xr-x) for directories and to 644 (-rw-r--r--) for files | |
# The permissions to $DIRS[] that need to be writeable are set to 775 (-rwxrwxr-x) for directories and | |
# 664 (-rw-rw-r--) for files. Add any assets directories, etc. as necessary. | |
# Change $BASE_DIR to the absolute path where your websites are stored (leaving it appended with '/$1') |
var $dateTime = new DateTime(); | |
$dateTime->setTimezone(new DateTimeZone('America/New_york')); | |
$dateTime->setTimestamp(time()); | |
$isDst = (bool)$dateTime->format('I') ? "y" : "n"; | |
$conf['daylight_savings'] = $isDst; |
{!-- | |
1. THE CHANNEL AND FIELD NAMES NEED TO BE CHECKED FOR ACCURACY | |
2. THE DYNAMIC LINK PATHS NEED TO BE CHECKED FOR ACCURACY | |
--} | |
{exp:rss:feed channel="news"} | |
<?xml version="1.0" encoding="{encoding}"?> | |
<rss version="2.0" | |
xmlns:dc="http://purl.org/dc/elements/1.1/" | |
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" |
# stolen from http://github.com/cschneid/irclogger/blob/master/lib/partials.rb | |
# and made a lot more robust by me | |
# this implementation uses erb by default. if you want to use any other template mechanism | |
# then replace `erb` on line 13 and line 17 with `haml` or whatever | |
module Sinatra::Partials | |
def partial(template, *args) | |
template_array = template.to_s.split('/') | |
template = template_array[0..-2].join('/') + "/_#{template_array[-1]}" | |
options = args.last.is_a?(Hash) ? args.pop : {} | |
options.merge!(:layout => false) |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Flexbox test</title> | |
<style> | |
@media screen and (min-width: 30em) { | |
body { | |
width:100%; | |
display: -webkit-box; | |
display: -moz-box; |