View Theme-Sniff-Issue-Format
[New sniff] No disabling of the admin toolbar
#### Rule:
**ERROR** : No hiding of the admin bar - check if `show_admin_bar( false )` is called or if `add_filter( 'show_admin_bar', '__return_false' )` is somewhere in the code.
#### Theme check file covering this rule:
#### To do:
View shortcode.php
function sc_menu( $atts, $content = null, $shortcode_tag = '' ) {
$bgcolors = array(
'blue' => array(
'class' => 'bg-cd-1',
'label' => __( 'Blue', 'prohelvetia' ),
'yellow' => array(
'class' => 'bg-cd-2',
View customizer.php
* Checks for the Customizer.
class CustomizerCheck implements themecheck {
protected $error = array();
function check( $php_files, $css_files, $other_files) {
View wpzoo_edd_is_active_customer.php
* Check if user has a valid subscription
function wpzoo_edd_is_active_customer( $user_id = '' ) {
// Fail gracefully if EDD Software Licencing not active
if ( ! function_exists('edd_software_licensing') ) {
$license_keys = edd_software_licensing()->get_license_keys_of_user( $user_id );
View tabs.js
document.addEventListener('DOMContentLoaded', function(){
var tabs = {
tab1: document.getElementById('tab-link-1'),
tab2: document.getElementById('tab-link-2'),
tab3: document.getElementById('tab-link-3'),
tab4: document.getElementById('tab-link-4')
var content = {

Adding context to strings

A word or phrase may be ambiguous to a translator who will likely only see the string in the interface of their translation tool and not necessarily on the front-end of your theme. Ambiguity can arise when a term is used in more than one context.

The functions _x() or _ex() are used to add the context to a string. They are similar to __() and _e(), but have a comment as an additional argument.

The function can be used in differnt ways

  • Explain the use for words with double meaings
  • Give extra information about the string

Clone repo

Run following code to clone from GitHub. git clone

Install dependencies

Run composer to install the dependencies composer install

View fp5-speed-buttons.php
Plugin Name: Flowplayer speed buttons
Plugin URI:
Description: Add buttons to adjust the speed of the video. The styles are added in the child theme
Version: 0.1.0
Author: Ulrich Pogson
Author URI:
License: GPLv2
License URI:
View Theme-review-links
View functions.php
* Escaping for textarea values while leaving both double and single quotes unconverted.
* @param string $text
* @return string
function theme_slug_esc_text( $text ) {
return htmlspecialchars( $text, ENT_NOQUOTES, get_option( 'blog_charset' ) );