This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/*************************************************************** | |
* Function pxlcore_whistles_post_labels() | |
* Changes the post labels for the Whistles post type. | |
***************************************************************/ | |
function pxlcore_whistles_post_labels( $labels ) { | |
$labels->name = 'Snippets'; | |
$labels->singular_name = 'Snippet'; | |
$labels->menu_name = 'Snippets'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: wpamrk Page Children Shortcode | |
Plugin URI: http://markwilkinson.me | |
Description: A shortcode that outputs the current pages children either with or without their featured image. | |
Version: 0.1 | |
Author: Mark Wilkinson | |
Author URI: http://http://markwilkinson.me/ | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[wpmark_list_children images="true"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/****************************************************************************************** | |
* Class sensl_whistles_widget | |
* Builds the widget for adding post content to widgetized area extending WP_Widget | |
******************************************************************************************/ | |
class MDW_Widget extends WP_Widget { | |
function mdw_widget() { | |
$widget_ops = array( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function wpmark_widget_tag_cloud_args( $args ) { | |
$args[ 'smallest' ] = '1.5'; | |
$args[ 'largest' ] = '1.5'; | |
$args[ 'unit' ] = 'em'; | |
return $args; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* output instagram widget */ | |
the_widget( | |
'null_instagram_widget', | |
array( | |
'username' => 'username', | |
'title' => '', | |
'number' => '1', | |
'size' => 'large', | |
'target' => '_blank', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/*************************************************************** | |
* Function bct_make_whistles_public() | |
* Sets the whistles post type to be public | |
***************************************************************/ | |
function bct_make_whistles_public( $post_type, $args ) { | |
/* only proceed for the whistles post type */ | |
if ( 'whistle' != $post_type ) | |
return; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object(stdClass)#386 (26) { | |
["labels"]=> | |
object(stdClass)#373 (14) { | |
["name"]=> | |
string(8) "Whistles" | |
["singular_name"]=> | |
string(7) "Whistle" | |
["add_new"]=> | |
string(7) "Add New" | |
["add_new_item"]=> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/*************************************************************** | |
* Function wpmark_alter_homepage_posts_query() | |
* Alter query on homepage for show just 5 posts | |
***************************************************************/ | |
function wpmark_alter_homepage_posts_query( $query ) { | |
/* check this is not the main query, the admin - if so bail early */ | |
if( ! $query->is_main_query() || is_admin() ) | |
return; |
OlderNewer