Skip to content

Instantly share code, notes, and snippets.

View femmestem's full-sized avatar

Christine Feaster femmestem

  • San Francisco, CA
View GitHub Profile
@femmestem
femmestem / sfmc-ampscript-preference-center-test.html
Created February 27, 2020 21:39 — forked from wvpv/sfmc-ampscript-preference-center-test.html
SFMC AMPScript preference center test email
<html>
<body style="font-family:sans-serif">
<a href="%%profile_center_url%%">Base - Profile/Preference Center</a>
<br/><a href="%%subscription_center_url%%">Base - Subscription Center</a>
<br/><a href="%%unsub_center_url%%">Base - One-Click Unsubscribe</a>
<br/><a href='%%=MicrositeURL(1111,"subscriberMID", "4444")=%%'>Custom Profile/Preference Center</a>
<br/><a href='%%=MicrositeURL(2222,"subscriberMID", "4444")=%%'>Custom Subscription Center</a>
<br/><a href='%%=MicrositeURL(3333,"subscriberMID", "4444")=%%'>One-Click Unsubscribe</a>
<p>This email was sent by:
<b>%%Member_Busname%%</b>
<script type="text/javascript" runat="server">
// src: https://gist.github.com/wvpv/19777e1167d6ac91e2e8
Platform.Load("core", "1");
var debug = true;
var request = {};
SetVar("method", Request.Method)
@femmestem
femmestem / gist:0902dc203f16e8c5b76134cd87ba071b
Created March 26, 2017 04:23 — forked from rtrouton/gist:04b6c31762b84b85eb44d0c59d8e1cd2
Mac models not compatible with macOS Sierra
'MacBookPro4,1'
'MacPro2,1'
'MacBookPro5,1'
'MacBookPro1,1'
'MacBookPro5,3'
'MacBookPro5,2'
'iMac8,1'
'MacBookPro5,4'
'iMac5,1'
'iMac5,2'
@femmestem
femmestem / gist:b6bd0f5d3261233d32d18e46f7904c1b
Created March 26, 2017 04:22 — forked from rtrouton/gist:e6cf0f4064aea52fac2e5116c4b05f2e
Sierra compatible Macs, sorted by Model ID and board ID
MacBook9,1: 'Mac-9AE82516C7C6B903'
iMac14,1: 'Mac-031B6874CF7F642A'
iMac10,1: 'Mac-F2268DC8'
MacBookPro8,1: 'Mac-50619A408DB004DA'
MacBook6,1: 'Mac-F22C8AC8'
MacBookPro10,2: 'Mac-AFD8A9D944EA4843'
iMac12,2: 'Mac-942B59F58194171B'
iMac14,2: 'Mac-27ADBB7B4CEE8E61'
MacBook8,2: 'Mac-F305150B0C7DEEEF'
MacBookAir6,1: 'Mac-35C1E88140C3E6CF'
@femmestem
femmestem / filter_tracks.rb
Last active August 29, 2015 14:14
Unique Records Persisting Multiple Requests
def filter_tracks
# Does this need to be so high when JavaScript limits display to 14?
@limit ||= 50
# The query methods are responsible for adding their own offsets to this
# hash map; that way, changing or removing a query method doesn't affect any
# other method
# If you need persistence with your implementation of pagination,
# make a session/cookie instead of an instance variable
@tracks_offset ||= {}
@femmestem
femmestem / ios_scaling.js
Created December 16, 2014 16:44
iOS Scaling (bug fix)
// iOS scaling bug fix
(function(doc) {
var addEvent = 'addEventListener',
type = 'gesturestart',
qsa = 'querySelectorAll',
scales = [1, 1],
meta = qsa in doc ? doc[qsa]('meta[name=viewport]') : [];
function fix() {
meta.content = 'width=device-width,minimum-scale=' + scales[0] + ',maximum-scale=' + scales[1];
doc.removeEventListener(type, fix, true);
@femmestem
femmestem / cli_obstacle_course.sh
Last active August 29, 2015 13:56
Phase 0 Week 6: Command Line Obstacle Course
# Clone the directory and view files
git clone https://github.com/femmestem/CLI-Obstacle-Course.git
cd CLI-Obstacle-Course
ls
ls -ald
# Move files and directories
mv images app/assets/images
ls -a
cd app/views/static_pages
@femmestem
femmestem / class_boggle_board.rb
Last active August 29, 2015 13:55 — forked from dbc-challenges/0.2.1-boggle_class_from_methods.rb
Phase 0 Week 4 SOLO CHALLENGE: Create A Boggle Board
class BoggleBoard
def initialize(board)
@board = board
end
def letter_at(coord)
@board[coord.first][coord.last]
end