Skip to content

Instantly share code, notes, and snippets.

View amElnagdy's full-sized avatar

Ahmed Mohammed Nagdy amElnagdy

View GitHub Profile
/*
Theme Name: Twenty Sixteen Child
Template: twentysixteen
*/
add_action ( 'wp_enqueue_scripts', 'bootstrap_cdn_scripts_styles', 10 );
function bootstrap_cdn_scripts_styles() {
wp_enqueue_style( 'bootstrap-css', '//netdna.bootstrapcdn.com/bootstrap/3.0.3/css/bootstrap.min.css', array(), '3.0.3', 'all' );
wp_enqueue_script( 'bootstrap-js', '//netdna.bootstrapcdn.com/bootstrap/3.0.3/js/bootstrap.min.js', array(), '3.0.3', true );
}
function jlwp_register_mdlcss() {
wp_register_style( 'material.indigo-pink.min', get_stylesheet_directory_uri() .'/material.min.css', 'all' );
wp_enqueue_style( 'material.indigo-pink.min' );
}
add_action( 'wp_enqueue_scripts', 'jlwp_register_mdlcss' );
<?php
function my_theme_enqueue_styles() {
$parent_style = 'parent-style'; // This is 'twentysixteen-style' for the Twenty Sixteen theme.
wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' );
wp_enqueue_style( 'child-style',
get_stylesheet_directory_uri() . '/style.css',
array( $parent_style ),
wp_get_theme()->get('Version')
/*
Theme Name: Twenty Sixteen Child
Description: My Twenty Sixteen Child Theme
Author: Tahir Taous
Author URI: wpcolt.com
Template: twentysixteen
*/
<?php
// =============================================================================
// FUNCTIONS/GLOBAL/ADMIN/SIDEBARS.PHP
// -----------------------------------------------------------------------------
// Sets up functionality for unique page sidebars.
// =============================================================================
// =============================================================================
// TABLE OF CONTENTS
<h2 id="unique-string">I'm target Heading</h2>
<h2>I'm target Heading</h2>
<p id="unique-string">I'm target text</p>