Skip to content

Instantly share code, notes, and snippets.

View Natetronn's full-sized avatar

Nathan Doyle Natetronn

View GitHub Profile
#!/bin/sh
# Import a remote database into a local database
# ----------------------------------------------
#
# Based on http://danherd.net/quick-script-synchronise-from-a-remote-expressionengine-database/
#
# Don’t forget chmod +x to make the script executable.
#
# Change the extension to .command to run the script directly from OS X Finder.
@Natetronn
Natetronn / stash-columns.html
Created July 22, 2014 18:58
An easy way to build Columns in ExpressionEngine using Stash - This is a 2 column, 10 item per column, with pagination example
{exp:stash:set_list name="directory" parse_tags="yes"}
{exp:channel:entries channel="profile" disable="categories|category_fields|profile_data|pagination" status="open" limit="200"}
{stash:company}{profile_company}{/stash:company}
{stash:first_name}{profile_first_name}{/stash:first_name}
{stash:last_name}{profile_last_name}{/stash:last_name}
{stash:title}{profile_title}{/stash:title}
{stash:address}{profile_address}{/stash:address}
{stash:address2}{profile_address2}{/stash:address2}
@Natetronn
Natetronn / quotes
Created March 16, 2015 17:29
Thoughts on quotes
Quotes can be damaging if read from the wrong state of mind. Some of us forget a whole life of successes can not be wrapped into one sentence. Life is not always so easily repeated.
@Natetronn
Natetronn / craft-specific-syntax.md
Last active August 29, 2015 14:19
Craft CMS Project Specific Syntax Highlighting for HTML (Twig)
@Natetronn
Natetronn / hidden_configs.php
Created April 23, 2012 08:01
ExpressionEngine hidden configs
<?php
$EE = get_instance();
$config = $this->EE->config->config;
ksort($config);
foreach($config as $key => $value)
{
@Natetronn
Natetronn / state-abbrivated-dropdown.txt
Created June 20, 2012 18:28
P&T Dropdown ~ States with abbreviated value
AL : Alabama
AK : Alaska
AZ : Arizona
AR : Arkansas
CA : California
CO : Colorado
CT : Connecticut
DE : Delaware
FL : Florida
GA : Georgia
@Natetronn
Natetronn / _EXTENDED.htaccess
Created August 23, 2012 17:51 — forked from pauloelias/README.md
Extended ExpressionEngine .htaccess
# Secure .htaccess file
# ------------------------------
<Files .htaccess>
order allow,deny
deny from all
</Files>
# Don't show any directory without an index file
# ------------------------------
@Natetronn
Natetronn / .htaccess
Created August 23, 2012 18:20 — forked from MaxLazar/.htaccess
ExpressionEngine .htaccess template
# Standard .htaccess file
# Secure .htaccess file
<Files .htaccess>
order allow,deny
deny from all
</Files>
# Don't show any directory without an index file
Options -Indexes
@Natetronn
Natetronn / gist:3716607
Created September 13, 2012 18:45
Matrix naming conventions
{gallery_matrix_images}
<figure>
<img src="{mx_file_src}" alt="{mx_text_alt_tag}" />
<figcaption>{mx_textarea_caption}</figcaption>
</figure>
{/gallery_matrix_images}
@Natetronn
Natetronn / config.php
Created October 28, 2012 20:09 — forked from 1stevengrant/config.php
Fixes the daylight savings issue with EE
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;