Skip to content

Instantly share code, notes, and snippets.

View prestonw's full-sized avatar

Will prestonw

View GitHub Profile
@prestonw
prestonw / Pods.php
Created February 1, 2018 17:29
Pods attachments
<?php
if ( get_post_meta( get_the_ID(), 'image_field', false ) ){
$image_array = get_post_meta( get_the_ID(), 'image_field', false );
}
if ( $image_array ) {
echo '<ul>';
foreach ( $image_array as $image ) {
$class = "post-attachment mime-" . sanitize_title( $image->post_mime_type );
$thumbimg = wp_get_attachment_image( $image['ID'], 'thumbnail');
echo '<li class="' . $class . ' data-design-thumbnail">' . $thumbimg . '</li>';
@prestonw
prestonw / keybase.md
Created September 22, 2017 17:08
Keybase Proof

Keybase proof

I hereby claim:

  • I am prestonw on github.
  • I am wpreston (https://keybase.io/wpreston) on keybase.
  • I have a public key ASCAgKEtdUWJdijL8UknR_B2pPPU1TfSozLV6I5hTW_lXQo

To claim this, I am signing this object:

@prestonw
prestonw / reclaimWindows10.ps1
Created January 11, 2017 23:06 — forked from alirobe/reclaimWindows10.ps1
"Reclaim Windows 10" turns off a bunch of unnecessary Windows 10 telemetery, removes bloatware, and privacy invasions. Review and tweak before running. Scripts for reversing are included and commented. Fork via https://github.com/Disassembler0 (different defaults)
##########
# Win10 Initial Setup Script
# Author: Disassembler <disassembler@dasm.cz>
# Version: 1.7, 2016-08-15
# dasm's script: https://github.com/Disassembler0/Win10-Initial-Setup-Script/
# THIS IS A PERSONALIZED VERSION
# This script leaves more MS defaults on, including MS security features.
# Tweaked based on personal preferences for @alirobe 2016-11-16 - v1.7.1