Skip to content

Instantly share code, notes, and snippets.

View gabesumner's full-sized avatar

Gabe Sumner gabesumner

  • Salesforce
  • San Francisco, CA
View GitHub Profile
@gabesumner
gabesumner / fiddle.css
Last active November 19, 2023 06:01
Address Validation using the Google Maps API
body {
font: 12px verdana;
background-color: #5C87B2;
}
form {
max-width: 400px;
padding: 15px;
background-color: white;
}
Remote Changed ASU_Student_Record_Page FlexiPage force-app/main/default/flexipages/ASU_Student_Record_Page.flexipage-meta.xml
// ==UserScript==
// @name Hide Invision
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://salesforce.invisionapp.com/*
// @grant none
// ==/UserScript==
@gabesumner
gabesumner / Heroku.js
Last active September 17, 2018 15:11
DF18 Platform TM Scripts
// ==UserScript==
// @name Heroku Autocomplete Private Space
// @version 0.1
// @match https://dashboard.heroku.com/teams/align-technologies*
// @require https://code.jquery.com/jquery-3.3.1.min.js
// @grant none
// ==/UserScript==
function rewrite() {
$(".alert-warning").hide();
@gabesumner
gabesumner / sfdx
Last active August 31, 2018 01:48
A small bash script that provides shortcuts for several common Salesforce DX commands.
#!/bin/bash
case $1 in
list)
# sfdx list
/usr/local/bin/sfdx force:org:list
;;
push)
if [ "$2" == "over" ]
then
@gabesumner
gabesumner / gist:a8a3ac290fae1acc02f33479caf2a896
Last active March 16, 2018 00:14
TamperMonkey Heroku Search/Replace Names
// ==UserScript==
// @name         TamperMonkey Heroku Search/Replace Names
// @match       https://dashboard.heroku.com/*
// @grant none
// ==/UserScript==
function replaceDreamhouse() {
var replaceArry = [
[/dreamhouse/gi, 'pecten']
];
@gabesumner
gabesumner / ToolsFile.xml
Created September 23, 2011 15:37
My favorite customizations for Sitefinity's Rich Text Editor
<?xml version="1.0" encoding="utf-8" ?>
<root>
<modules>
<module name="RadEditorStatistics" dockingZone="Bottom" visible="false" />
<module name="RadEditorDomInspector" visible="false" />
<module name="RadEditorNodeInspector" visible="false" />
<module name="RadEditorHtmlInspector" visible="false" />
</modules>
<tools name="MainToolbar">
<tool name="ToggleAdvancedToolbars"/>
@gabesumner
gabesumner / HelloWorld.ascx
Created August 25, 2011 22:56
HelloWorld example for Sitefinity 4 custom Widgets and ControlDesigners
<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="HelloWorld.ascx.cs" Inherits="SitefinityWebApp.Widgets.HelloWorld" %>
<p>Hello <asp:Literal ID="NameLiteral" runat="server" /></p>
@gabesumner
gabesumner / worst-practice.html
Created July 27, 2012 16:52
Worst practices for creating a CMS template design
<!doctype html>
<html>
<head>
<title>Sushi Mockup</title>
<!-- Nothing wrong with this block of styling. Collapse or keep scrolling. -->
<style type="text/css">
*
{
margin: 0;
padding: 0;
@gabesumner
gabesumner / gist:2148657
Created March 21, 2012 15:40
Provides a short URL slug based on the database row ID. This is done by converting a (Base10) Int into a (Base64) String
using System;
using System.Linq;
using System.Text.RegularExpressions;
namespace MvcApplication.Helpers
{
public static class ShortUrl
{
/// <summary>
/// Converts a Base-10 Integer to Base-64. This will effectively shorten the number of characters used to represent a number > 10.