most of these require logout/restart to take effect
# Enable character repeat on keydown
defaults write -g ApplePressAndHoldEnabled -bool false
# Set a shorter Delay until key repeat| add_filter( 'image_send_to_editor', 'tiny_force_caption', 100 ); | |
| function tiny_force_caption( $html ) { | |
| $a = strpos($html, 'caption'); | |
| if ($a!=1) { | |
| preg_match('/(alignnone|alignleft|alignright|aligncenter)/', $html,$c); | |
| preg_match('/width="(\d*)"/', $html,$w); | |
| preg_match('/alt="([^"]*)"/', $html,$m); | |
| preg_match('/wp-image-(\d*)"/', $html,$n); | |
| if (!isset($n[1])) $n[1] = '0'; | |
| $html = '[caption id="attachment_'.$n[1].'" align="'.($c?$c[1]:'alignnone').'" width="'.$w[1].'"]'.$html." © ".get_bloginfo('title')."[/caption]"; |
| git log --reverse --date=short --pretty=format:'{%n "headline": "%H",%n "author": "%an <%ae>",%n "startDate": "%ad",%n "text": "%s "%n},' > ~/Desktop/json_log.txt |
| <!doctype html> | |
| <!-- http://taylor.fausak.me/2015/01/27/ios-8-web-apps/ --> | |
| <html> | |
| <head> | |
| <title>iOS 8 web app</title> | |
| <!-- CONFIGURATION --> |
This is a simple liquid tag that helps to easily embed images, videos or slides from OEmbed enabled providers. It uses Magnus Holm's great oembed gem which connects to the OEmbed endpoint of the link's provider and retrieves the HTML code to embed the content properly (i.e. an in-place YouTube player, Image tag for Flickr, in-place slideshare viewer etc.). By default it supports the following OEmbed providers (but can fallback to Embed.ly or OoEmbed for other providers):