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 | |
add_theme_support( 'starter-content', array( | |
'attachments' => array( | |
'featured-image-logo' => array( | |
'post_title' => 'Featured Logo', | |
'post_content' => 'Attachment Description', | |
'post_excerpt' => 'Attachment Caption', | |
'file' => 'assets/images/featured-logo.jpg', | |
), | |
), |
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 | |
add_action( 'after_setup_theme', 'theme_start_content' ); | |
function theme_starter_content() { | |
add_theme_support( 'starter-content', array( | |
'posts' => array( | |
'home', | |
'about', | |
'contact', |
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 | |
add_action( 'after_setup_theme', 'theme_start_content' ); | |
function theme_starter_content() { | |
add_theme_support( 'starter-content', array( | |
'posts' => array( | |
'test' => array( | |
'post_type' => 'page', | |
'post_title' => _x( 'Das ist ein Test', 'theme-slug' ), |
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 Mein_Widget extends WP_Widget { | |
function __construct() { | |
// Instantiate the parent object | |
parent::__construct( 'meine-base-id', _x( 'My widget', 'theme-slug' ) ); | |
} | |
function widget( $args, $instance ) { |
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 | |
add_action( 'after_setup_theme', 'theme_start_content' ); | |
function theme_starter_content() { | |
add_theme_support( 'starter-content', array( | |
'widgets' => array( | |
'sidebar-1' => array( | |
'text_business_info', | |
'search', | |
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 | |
add_action( 'after_setup_theme', 'theme_start_content' ); | |
function theme_starter_content() { | |
add_theme_support( 'starter-content', array( | |
'widgets' => array( | |
'sidebar-1' => array( | |
'text_business_info', | |
'search', | |
), |
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: Nonces in der REST API | |
* Author: Websupporter | |
* Plugin URL: http://websupporter.net/blog/de/nonces-in-der-rest-api/ | |
* Licence: GPL | |
**/ | |
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: Nonces in der REST API Not working | |
* Author: Websupporter | |
* Plugin URL: http://websupporter.net/blog/de/nonces-in-der-rest-api/ | |
* Licence: GPL | |
**/ | |
add_action( 'wp_ajax_nonce-test', 'ajax_nonce_test' ); |
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 | |
add_action( 'after_setup_theme', 'add_frontkit_support' ); | |
function add_frontkit_support() { | |
add_theme_support( 'frontkit', array( | |
'title' => '.single-post .entry-title', | |
'content' => '.single-post .entry-content', | |
) ); | |
} |