This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
<?php | |
/* | |
* Solution to order first by date, then by start time (both are meta values) | |
* http://wordpress.stackexchange.com/a/67391/5045 | |
* */ | |
add_action( 'pre_get_posts', 'pre_get_posts_programpunkter' ); | |
function pre_get_posts_programpunkter( $query ) { | |
if( !is_admin() && is_post_type_archive( 'programpunkt' ) && $query->is_main_query() ) { |
<?php | |
/* | |
* Usage for a custom post type named 'movies': | |
* unregister_post_type( 'movies' ); | |
* | |
* Usage for the built in 'post' post type: | |
* unregister_post_type( 'post', 'edit.php' ); | |
*/ | |
function unregister_post_type( $post_type, $slug = '' ){ |
<?php | |
// loop through the sub-pages of your custom post type | |
$childpages = new WP_Query( array( | |
'post_type' => 'work', | |
'post_parent' => $this_page, | |
'posts_per_page' => 100, | |
'orderby' => 'menu_order' | |
)); | |
while ( $childpages->have_posts() ) : $childpages->the_post(); ?> |
<?php | |
# Register custom post types on the 'init' hook. | |
add_action( 'init', 'my_register_post_types' ); | |
/** | |
* Registers post types needed by the plugin. | |
* | |
* @since 1.0.0 | |
* @access public |
<?php | |
/** | |
* Gravity Wiz // Disable HTML5 Validation on Gravity Forms | |
* http://gravitywiz.com/disable-html5-validation-on-gravity-forms/ | |
*/ | |
add_filter( 'gform_form_tag', 'add_no_validate_attribute_to_form_tag' ); | |
function add_no_validate_attribute_to_form_tag( $form_tag ) { | |
return str_replace( '>', ' novalidate="novalidate">', $form_tag ); | |
} |
{% capture the_collection %}{{page.collection}}{% endcapture %} | |
{% if page.collection %} | |
{% assign document = site[the_collection] %} | |
{% endif %} | |
<h1>TITLE: {{ page.title }}</h1> | |
{% for links in document %} | |
{% if links.title == page.title %} | |
{% unless forloop.first %} | |
{% assign prevurl = prev.url %} | |
{% endunless %} |
add_filter( 'the_content', function( $content ) { | |
$response = wp_remote_get( 'http://ben.lobaugh.net/wp-json/posts' ); | |
if( '200' == wp_remote_retrieve_response_code( $response ) ) { | |
$posts = json_decode( wp_remote_retrieve_body( $response ) ); | |
foreach( $posts AS $p ) { | |
echo $p->title->rendered . "<br/>"; |
'use strict'; | |
angular.module('wordpress', []) | |
.service( 'wpService', | |
function($http, $q){ | |
var url = 'http://allin.local/wp-json/'; | |
return({ |