Skip to content

Instantly share code, notes, and snippets.

View scottpdawson's full-sized avatar
🏠
Writing, designing, and coding from home since 1998

Scott Dawson scottpdawson

🏠
Writing, designing, and coding from home since 1998
View GitHub Profile
library(plotKML)
# Find GPX files using a pattern
files <- dir(pattern = "\\.gpx")
# Consolidate routes in one drata frame
index <- c()
latitude <- c()
longitude <- c()
for (i in 1:length(files)) {
@scottpdawson
scottpdawson / crowdfire.js
Last active October 7, 2017 11:48
When Crowdfire updated their service to show a checkmark after you've taken action on a profile instead of just hiding the profile, they ruined the usability of their service. If you paste this in your browser console on each page load, it reverts the functionality back to what it was before. Is there a way to have this load automatically?
$(document).on("click", function() {
$(".js-done-button:visible").closest(".row").hide();
});
<?php
add_action("wp_enqueue_scripts", "my_enqueue", 11);
function my_enqueue() {
wp_deregister_script('jquery');
wp_register_script('jquery', "http" . ($_SERVER['SERVER_PORT'] == 443 ? "s" : "") . "://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js", false, null);
wp_enqueue_script('jquery');
wp_enqueue_script( 'function', get_stylesheet_directory_uri().'/js/gallery_script.js', 'jquery', true);
}
// add actions to respond to get_gallery_data