Skip to content

Instantly share code, notes, and snippets.


Peter Hanley hanleybrand

View GitHub Profile
hanleybrand / gist:8e88211bda55f1d165b7efa791d763b5
Created May 19, 2017 — forked from brent20/gist:3692482
BLTI Navigation External tool- External Link inside of Instructure Canvas - Brent Saltzman, Creighton University
View gist:8e88211bda55f1d165b7efa791d763b5
<cartridge_basiclti_link xmlns=""
<blti:title>External non-BLTI URL</blti:title>
<blti:description>This tool adds a Course Navigation item to a URL specified in the URL tag, after configuration it can be found under the navigation settings</blti:description>
hanleybrand / users_notenrolled_notlog.sql
Last active May 9, 2017 — forked from enriquemanuel/users_notenrolled_notlog.sql
Oracle SQL - Bb Learn - Finding Users that have not logged in to the System and are not enrolled in any course
View users_notenrolled_notlog.sql
-- Finding Users that have not logged in to the System and are not enrolled in any course
SELECT u.user_id, u.last_login_date
FROM BBLEARN.users u WHERE NOT EXISTS (SELECT pk1 FROM BBLEARN.course_users WHERE users_pk1=u.pk1 )
and u.last_login_date is null
-- and u.system_role = 'N' -- if we want to limit by the system role
order by user_id asc;
hanleybrand /
Last active Aug 29, 2015 — forked from anthonywu/
Mac OS X bash alias for concatenating pdf files - usage: pdf_join output_file.pdf [list of files]
function pdf_join {
join_py="/System/Library/Automator/Combine PDF Pages.action/Contents/Resources/"
read -p "Name of output file > " output_file && "$join_py" -o $output_file $@ && open $output_file
hanleybrand / 0_reuse_code.js
Last active Aug 29, 2015
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
hanleybrand / webapp_vpat
Last active Aug 29, 2015 — forked from anonymous/webapp_vpat
Section 1194.22 Web-based Internet information and applications – Detail VPAT™ Voluntary Product Accessibility Template® source:
View webapp_vpat
(a) A text equivalent for every non-text element shall be provided (e.g., via "alt", "longdesc", or in element content).
(b) Equivalent alternatives for any multimedia presentation shall be synchronized with the presentation.
(c) Web pages shall be designed so that all information conveyed with color is also available without color, for example from context or markup.
(d) Documents shall be organized so they are readable without requiring an associated style sheet.
(e) Redundant text links shall be provided for each active region of a server-side image map.
(f) Client-side image maps shall be provided instead of server-side image maps except where the regions cannot be defined with an available geometric shape.
(g) Row and column headers shall be identified for data tables.
(h) Markup shall be used to associate data cells and header cells for data tables that have two or more logical levels of row or column headers.
(i) Frames shall be titled with text that facilitates frame identification and navigation
hanleybrand /
Created May 31, 2014
Django [copy database] - management command
from optparse import make_option
from django.core import serializers
from django.db.models import get_app, get_models
__author__ = 'mikhailturilin'
from import BaseCommand
Exports Issues from a specified repository to a CSV file
Uses basic authentication (Github username + password) to retrieve Issues
from a repository that username has access to. Supports Github API v3.
import csv
import requests
View bookmarklet.js
(function() {
var s=document.createElement('script');
if(typeof jQuery!='undefined') {
var msg='This page already using jQuery v' + jQuery.fn.jquery;
} else {
var msg='This page is now jQuerified'
#!/usr/bin/env python
"""Command line script to convert a file, usually an image, into a data URI
for use on the web."""
import base64
import mimetypes
import os
import sys
hanleybrand / loggedin.html
Created Oct 12, 2012 — forked from Miserlou/
Django Filter By Users Last Logged In
View loggedin.html
{%for u in users%}
{{u}} - {{u.last_login}}<br />
{% endfor %}