Skip to content

Instantly share code, notes, and snippets.

View degoya's full-sized avatar

Alexander Herling degoya

View GitHub Profile
@degoya
degoya / getPageFeed.php
Created November 19, 2016 03:58 — forked from nick2687/getPageFeed.php
Simple modx snippet that will pull facebook page feed data and display it using a chunk
<?php
// Facebook App id & secret
$fb_app_id = isset($fb_app_id) ? $fb_app_id : NULL;
$fb_app_secret = isset($fb_app_secret) ? $fb_app_secret : NULL;
$access_token = $fb_app_id . '|' . $fb_app_secret;
// Other options
$page_id = isset($page_id) ? $page_id : NULL ;
$chunk = isset($chunk) ? $chunk : 'getPageFeedTpl' ;
@degoya
degoya / magento-nginx.conf
Created October 23, 2015 11:09 — forked from gwillem/magento-nginx.conf
Battle-tested Nginx configuration for Magento (source: www.hypernode.com)
# This is an annotated subset of the Nginx configuration from our Magento production platform @ www.hypernode.com
# See https://www.byte.nl/blog/magento-cacheleak-issue
user app;
worker_processes 4;
pid /var/run/nginx.pid;
events {
worker_connections 768;
}
@degoya
degoya / recipient.php
Last active April 7, 2022 13:19 — forked from mkay/recipient.php
MODX FormIt custom hook example.
<?php
// Type: Snippet
$recipient = $hook->getValue('reason');
if($recipient == 'one'){
$email = '';
}
elseif($recipient == 'two'){
$email = '';
}