This file contains hidden or 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
| img.grayscale.disabled { | |
| filter: url("data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\'><filter id=\'grayscale\'><feColorMatrix type=\'matrix\' values=\'1 0 0 0 0, 0 1 0 0 0, 0 0 1 0 0, 0 0 0 1 0\'/></filter></svg>#grayscale"); | |
| -webkit-filter: grayscale(0%); | |
| } |
This file contains hidden or 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
| /* ------------------------------------------------------------------*/ | |
| /* ADD PRETTYPHOTO REL ATTRIBUTE FOR LIGHTBOX */ | |
| /* ------------------------------------------------------------------*/ | |
| add_filter('wp_get_attachment_link', 'rc_add_rel_attribute'); | |
| function rc_add_rel_attribute($link) { | |
| global $post; | |
| return str_replace('<a href', '<a rel="prettyPhoto[pp_gal]" href', $link); | |
| } |
This file contains hidden or 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
| var parser = document.createElement('a'); | |
| parser.href = "http://example.com:3000/pathname/?search=test#hash"; | |
| parser.protocol; // => "http:" | |
| parser.hostname; // => "example.com" | |
| parser.port; // => "3000" | |
| parser.pathname; // => "/pathname/" | |
| parser.search; // => "?search=test" | |
| parser.hash; // => "#hash" | |
| parser.host; // => "example.com:3000" |
This file contains hidden or 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 | |
| $posts = multisite_latest_post( array( | |
| "how_many"=>10, | |
| "how_long_days"=>30, | |
| "how_many_words"=>50, | |
| "more_text"=>"[...]", | |
| "remove_html"=>true, | |
| "sort_by"=>"post_date", | |
| // if paginating: | |
| "paginate"=>true, |
This file contains hidden or 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: Test | |
| */ | |
| class My_Like_Button { | |
| function __construct() | |
| { | |
| $this->hooks(); | |
| } |
This file contains hidden or 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 | |
| // Register the column | |
| function price_column_register( $columns ) { | |
| $columns['price'] = __( 'Price', 'my-plugin' ); | |
| return $columns; | |
| } | |
| add_filter( 'manage_edit-post_columns', 'price_column_register' ); |
This file contains hidden or 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
| # add to | |
| functions.php | |
| // This theme uses post thumbnails | |
| add_theme_support( 'post-thumbnails' ); | |
| set_post_thumbnail_size( 300, 300, true ); | |
| add_image_size( 'thumbnail-small', 75, 9999 ); | |
| add_image_size( 'thumbnail-medium', 500, 9999 ); | |
NewerOlder