Skip to content

Instantly share code, notes, and snippets.

View arbitrarily's full-sized avatar

Marko Bajlovic arbitrarily

View GitHub Profile
@ericelliott
ericelliott / essential-javascript-links.md
Last active April 30, 2026 08:09
Essential JavaScript Links
@benwo
benwo / meta-tags.html
Last active April 9, 2025 08:20
Standard meta tags and meta image tags (and sizes).
<!DOCTYPE html>
<html itemscope itemtype="http://schema.org/Organization" lang="en">
<head>
<!-- Settings -->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Search Engines -->
@ciaranmahoney
ciaranmahoney / mixpanel-page-linktracking-wordpress.php
Last active March 24, 2017 15:12
This gist inserts MixPanel link click and pageview tracking scripts into a WordPress blog. It is intended to be included in footer.php so it can track pageview and clicks for all pages. In order for this to work, you must have a Mixpanel account and have Mixpanel tags setup on your website.
<!-- MixPanel Link click tracking - track clicks for all links -->
<script type="text/javascript">// <![CDATA[
mixpanel.track_links("a", "Link Click", {
"referrer": document.referrer
});
// ]]>
</script>
<!-- MixPanel Pageview tracking -->
<?php if( is_page()) { // Sets page type to Page for all pages ?>
@kevinwhoffman
kevinwhoffman / loop-custom.php
Last active July 17, 2024 14:47
WordPress - Custom Post Type Loop
<?php
$loop = new WP_Query( array(
'post_type' => 'Property',
'posts_per_page' => -1
)
);
?>
<?php while ( $loop->have_posts() ) : $loop->the_post(); ?>
@kevinelliott
kevinelliott / osx-10.10-setup.md
Last active May 5, 2026 07:20
Mac OS X 10.10 Yosemite Setup

Mac OS X 10.10 Yosemite

Custom recipe to get OS X 10.10 Yosemite running from scratch, setup applications and developer environment. I use this gist to keep track of the important software and steps required to have a functioning system after a semi-annual fresh install. On average, I reinstall each computer from scratch every 6 months, and I do not perform upgrades between distros.

This keeps the system performing at top speeds, clean of trojans, spyware, and ensures that I maintain good organizational practices for my content and backups. I highly recommend this.

You are encouraged to fork this and modify it to your heart's content to match your own needs.

Install Software

@nroca
nroca / gist:511ef1d287ba7121f596
Created October 9, 2014 05:39
ACF Options Page (Icon/Position)
// http://support.advancedcustomfields.com/forums/topic/change-menu-position-of-options-page/
acf_add_options_page( array(
'page_title' => 'Home Page Sliders',
'menu_title' => 'Sliders',
'menu_slug' => 'home-page-sliders',
'capability' => 'edit_posts',
'icon_url' => 'dashicons-images-alt2',
'position' => 7
@matthewmueller
matthewmueller / osx-for-hackers.sh
Last active May 15, 2026 06:38
OSX for Hackers (Mavericks/Yosemite)
# OSX for Hackers (Mavericks/Yosemite)
#
# Source: https://gist.github.com/brandonb927/3195465
#!/bin/sh
# Some things taken from here
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
# Ask for the administrator password upfront
## This file should be present in the same directory as the EFISTUB kernel and initramfs files
## More info at http://www.rodsbooks.com/refind/linux.html , http://www.rodsbooks.com/efi-bootloaders/efistub.html
"Boot with defaults" "root=PARTUUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx rootfstype=btrfs rw quiet splash systemd.unit=graphical.target radeon.modeset=1 radeon.audio=1 radeon.dpm=1 acpi_backlight=vendor console=tty0"
"Boot with nosplash" "root=PARTUUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx rootfstype=btrfs rw quiet systemd.unit=graphical.target radeon.modeset=1 radeon.audio=1 radeon.dpm=1 acpi_backlight=vendor console=tty0"
"Boot with message" "root=PARTUUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx rootfstype=btrfs rw systemd.unit=graphical.target radeon.modeset=1 radeon.audio=1 radeon.dpm=1 acpi_backlight=vendor console=tty0"
"Boot to terminal" "root=PARTUUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx rootfstype=btrfs rw systemd.unit=multi-user.target radeon.modeset=1 radeon.audio=1 radeon.dpm=1 ac
@hdragomir
hdragomir / sm-annotated.html
Last active April 30, 2026 08:09
The deferred font loading logic for Smashing Magazine. http://www.smashingmagazine.com/
<script type="text/javascript">
(function () {
"use strict";
// once cached, the css file is stored on the client forever unless
// the URL below is changed. Any change will invalidate the cache
var css_href = './index_files/web-fonts.css';
// a simple event handler wrapper
function on(el, ev, callback) {
if (el.addEventListener) {
el.addEventListener(ev, callback, false);