Skip to content

Instantly share code, notes, and snippets.

View ademers's full-sized avatar
🧡

Andrea ademers

🧡
View GitHub Profile
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Contact Form Plugin Example with Axios</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/axios/0.18.0/axios.js"></script>
</head>
<body>
<!--
<?php
use craft\test\TestSetup;
ini_set('date.timezone', 'UTC');
// Use the current installation of Craft
define('CRAFT_STORAGE_PATH', __DIR__ . '/_craft/storage');
define('CRAFT_TEMPLATES_PATH', __DIR__ . '/_craft/templates');
define('CRAFT_CONFIG_PATH', __DIR__ . '/_craft/config');
actor: Tester
paths:
tests: tests
log: tests/_output
data: tests/_data
support: tests/_support
envs: tests/_envs
settings:
bootstrap: _bootstrap.php
params:
@ademers
ademers / export.php
Last active July 20, 2018 15:54 — forked from engram-design/export.php
ExpressionEngine PHP Export into JSON: Members by group
<?php
$group = $_GET['id'];
$content = array();
$entries_query = $this->EE->db->query("SELECT * FROM exp_members WHERE exp_members.group_id = '$group'");
foreach ($entries_query->result_array() as $id => $row) {
$content[$id] = array();
// Remove spaces from EE usernames
@ademers
ademers / .gitignore
Created February 15, 2017 22:07 — forked from octocat/.gitignore
Some common .gitignore configurations
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
# Packages #
Here are a few questions that will tee us up for a good conversation:
- Can you tell me about your project in a few sentences?
- What’s the timeframe? Does a certain event depend on this project launching?
- What are you looking for from us? Do you want us to design, build, and launch the whole site? Or do you have developers or other partners lined up and only need us for design?
- Have you already started on any part of the project? Do you have existing work? A new logo? Some rough designs or ideas for the site?
- How large is your team? What are the roles you envision on your end?
- How did you hear about our work? What specifically interests you about it? Any projects that you’re keen on?
- How much money have you set aside for this project?
- Are you talking to others about this project? Might we ask how many? What do you like about their work?
@ademers
ademers / set-project-perms.sh
Created April 21, 2016 15:29 — forked from khalwat/set-project-perms.sh
Properly set permissions for a Craft CMS install, including ensuring that files are all g-x. Set CHOWN_USER, CHOWN_GROUP, and BASE_DIR to whatever is appropriate, add directories that need to be writeable by the web server to DIRS[], then execute: sudo ./set-project-perms.sh PROJECT_NAME
#!/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')
@ademers
ademers / gist:4036322
Created November 8, 2012 02:54 — forked from lucasfais/gist:1207002
Sublime Text 2 - Useful Shortcuts

Sublime Text 2 – Useful Shortcuts (Mac OS X)

General

⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
@ademers
ademers / related_entries.html
Created October 14, 2012 16:11 — forked from iso100/related_entries.html
Related entries in Statamic via taxonomy tags
@ademers
ademers / meat-tornado
Created October 14, 2012 16:10 — forked from jackmcdade/meat-tornado
Statamic Exceprt
---
title : Meat Tornado
excerpt: Bacon ipsum dolor sit amet drumstick spare ribs pastrami ground round, jerky pork chuck pork chop ham hock tail corned beef chicken andouille tongue biltong. Venison short ribs swine meatball prosciutto strip steak pork, tongue pancetta ham jerky. Bacon pig filet mignon.
---
Bacon ipsum dolor sit amet drumstick spare ribs pastrami ground round, jerky pork chuck pork chop ham hock tail corned beef chicken andouille tongue biltong. Venison short ribs swine meatball prosciutto strip steak pork, tongue pancetta ham jerky. Bacon pig filet mignon brisket pork beef, meatball shoulder turkey swine tongue. Andouille sausage shankle, beef ribs pancetta pork loin corned beef flank brisket meatloaf ham hock short loin pastrami. Leberkas capicola tail pork belly rump, pig spare ribs pork.
Drumstick prosciutto tail, ham hock pork loin swine tongue frankfurter cow andouille shankle sausage chuck boudin. Ham hock rump ribeye pork belly ball tip, salami pig jerky. Tri-tip bacon tenderloin,