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
p.comment-form-rating{float:left;display:inline-block;margin-right:5px;height:32px;} | |
p.stars:after,p.comment-form-rating:after{content:"";display:block;clear:both;} | |
p.stars span{width:80px;height:16px;position:relative;float:left;background:url(img/star.png) repeat-x left 0;} | |
p.stars span a{float:left;position:absolute;left:0;top:0;width:16px;height:0;padding-top:16px;overflow:hidden;} | |
p.stars span a:focus,p.stars span a:hover{background:url(img/star.png) repeat-x left -16px;} | |
p.stars span a.star-1{width:16px;z-index:10;} | |
p.stars span a.star-2{width:32px;z-index:9;} | |
p.stars span a.star-3{width:48px;z-index:8;} | |
p.stars span a.star-4{width:64px;z-index:7;} | |
p.stars span a.star-5{width:80px;z-index:6;} |
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
// Unload CF7 assests | |
add_filter( 'wpcf7_load_js', '__return_false' ); | |
add_filter( 'wpcf7_load_css', '__return_false' ); | |
add_action( 'the_content', 'load_cf7_assets' ); | |
function load_cf7_assets($content){ | |
global $post; | |
// Load assests when content contains CF7 shortcode. | |
$post_content = $post->post_content; | |
if ( has_shortcode( $post_content, 'contact-form-7' ) ) { // Check if content contains CF7 shortcode |
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
function unregister_default_wp_widgets() { | |
unregister_widget('WP_Widget_Pages'); | |
unregister_widget('WP_Widget_Calendar'); | |
unregister_widget('WP_Widget_Archives'); | |
unregister_widget('WP_Widget_Links'); | |
unregister_widget('WP_Widget_Meta'); | |
unregister_widget('WP_Widget_Categories'); | |
unregister_widget('WP_Widget_Recent_Comments'); | |
unregister_widget('WP_Widget_Tag_Cloud'); | |
unregister_widget('WP_Widget_RSS'); |
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
function deregister_migrate() { | |
if ( !is_admin() ) { | |
wp_deregister_script('jquery'); | |
} | |
} | |
add_action('wp_enqueue_scripts', 'deregister_migrate'); |
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 | |
/** | |
* Numeric Pagination Class | |
* @author Alexandre Plennevaux https://pixeline.be | |
* | |
* This class returns a list of LI > A. It is up to you to set the wrapping NAV > UL around your function call. | |
* | |
* @usage (setting specific classes) | |
* | |
* // Sets the css classes you want to be used for the 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
/* | |
##Device = Desktops | |
##Screen = 1281px to higher resolution desktops | |
*/ | |
@media (min-width: 1281px) { | |
//CSS | |
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
/* Smartphones (portrait and landscape) ----------- */ | |
@media only screen | |
and (min-device-width : 320px) | |
and (max-device-width : 480px) { | |
/* STYLES GO HERE */ | |
} | |
/* Smartphones (landscape) ----------- */ | |
@media only screen | |
and (min-width : 321px) { |
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 | |
if (function_exists('wpcf7')) { | |
echo do_shortcode( '[contact-form-7 id="413" title="Contact form 1"]' ); | |
} else { | |
echo "<p class='title'>Please install <a href='http://wordpress.org/plugins/contact-form-7/' rel='nofollow'>Contact Form 7</a> plugin and build some contact form. Then use your shortcode on the contact page.</p>"; | |
} | |
?> |
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
//to add defer to loading of scripts - use defer to keep loading order | |
function script_tag_defer($tag, $handle) { | |
if (is_admin()){ | |
return $tag; | |
} | |
if (strpos($tag, '/wp-includes/js/jquery/jquery')) { | |
return $tag; | |
} | |
if (strpos($_SERVER['HTTP_USER_AGENT'], 'MSIE 9.') !==false) { | |
return $tag; |
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
function custom_unregister_theme_post_types() { | |
global $wp_post_types; | |
if ( isset( $wp_post_types["agent"] ) ) { | |
unset( $wp_post_types[ "agent" ] ); //UPDATED | |
} | |
} | |
add_action( 'init', 'custom_unregister_theme_post_types', 20 ); |
OlderNewer