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 one or more classes to the WordPress comment form's 'Submit' button | |
* NB: This only works as of WordPress 4.1 | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* @link http://www.brightnucleus.com/add-class-wordpress-comment-submit-button/ | |
* | |
* @param array $arg contains all the default values used by the comment form | |
* @return array modified array that goes back to the comment renderer |
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 one or more classes to the WordPress search form's 'Search' button | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* @link http://www.brightnucleus.com/add-class-wordpress-search-button/ | |
* | |
* @param string $form the search form HTML output | |
* @return string modified version of the search form HTML output | |
* |
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 one or more classes to the Genesis search form's 'Submit' button | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* @link http://www.brightnucleus.com/add-class-wordpress-search-button/ | |
* | |
* @param string $form the search form HTML output | |
* @param string $search_text text inside the search text entry box | |
* @param string $button_text caption of the search button |
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 the SVG Mime type to the uploader | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* | |
* @param array $mimes list of mime types that are allowed by the | |
* WordPress uploader | |
* @return array modified version of the $mimes 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 | |
/** | |
* Replace WordPress standard SVG width of 1 with 100% | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* | |
* By default, WordPress renders all SVG files uploaded through the Media | |
* Uploader with both width and height at "1". | |
* | |
* @param string $output HTML output that Genesis has generated for a |
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 | |
/** | |
* Move Genesis child theme style sheet to a much later priority to give any plugins a chance to load first. | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* | |
* @see http://docs.garyjones.co.uk/genesis/2.0.0/function-genesis_load_stylesheet.html | |
*/ | |
function as_postpone_genesis_stylesheet() { |
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 | |
/** | |
* Shortcode to display copyright notice with current year | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
*/ | |
function as_shortcode_copyright() { | |
// generate output in the form of "(C) 2015 Greatest Blog Ever" | |
$copyright = '© ' . date( 'Y' ) . ' ' . get_bloginfo( 'name' ); |
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 | |
/** | |
* Modify location of main stylesheet | |
* N.B.: style.css in the theme's root is still needed to provide WordPress | |
* with the necessary metadata about the theme | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* | |
* @param string $stylesheet_uri Stylesheet URI for the current theme/ | |
* child theme |
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
/** | |
* Reflowing columns (CSS Multi-column) | |
* | |
* This defines reflowing columns in CSS. Simply apply the class with the number | |
* of columns you need, like .reflow-3 . The number of columns wil be reduced if | |
* the individual columns go below $min-column-width. | |
* | |
* IE10+ only, all but Firefox have trouble displaying <li>s inside the columns. | |
* | |
* @author Alain Schlesser <alain.schlesser@gmail.com> |
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 | |
/** | |
* Translatable string with multiple links that can be reordered and renamed | |
* @author Alain Schlesser (alain.schlesser@gmail.com) | |
* | |
* @see http://php.net/manual/function.preg-replace.php | |
* @see http://codex.wordpress.org/Function_Reference/_2 | |
*/ |
OlderNewer