T
NOVI APDEJTOVANIContinue reading
Join 2,000,000+ Professionals who use WPCode to Future-Proof Their Websites!
NOVI APDEJTOVANIContinue reading
add_filter( ‘the_content’, function ( $content ) { // Return early if it is a single post. if ( is_singular( ‘post’ ) ) { return $content; } return str_replace( ‘Continue reading
if(!function_exists(‘wp_get_attachment’) ) : function wp_get_attachment( $attachment_id ) { $attachment = get_post($attachment_id); if( $attachment ) { $caption = function_exists(‘aioseoImageSeo’) ? aioseoImageSeo()->tags->replaceTags(aioseo()->options->image->caption->format, $attachment->ID, ‘caption’) : $attachment->post_excerpt; return array( ‘alt’ => get_post_meta($attachment->ID, ‘_wp_attachment_image_alt’, true), ‘caption’ => $caption, ‘description’ => $attachment->post_content, ‘href’ => esc_url(get_permalink($attachment->ID)),…Continue reading
add_filter( ‘tasty_pins_old_attributes_migration_content’, function ( $content, $post ) { if ( str_contains( $content, ‘WP Tasty’ ) ){ update_post_meta( $post->ID, ‘wp-tasty-here’, true ); } // You can also change $content to modify the contents of the post. return $content; }, 10, 2…Continue reading
add_filter(‘perfmatters_delay_js_timeout’, function($timeout) { return ‘3’; });Continue reading
document.addEventListener(“DOMContentLoaded”, function () { // Get all Read More buttons const readMoreButtons = document.querySelectorAll(‘.read-more’); readMoreButtons.forEach(button => { button.addEventListener(‘click’, function (event) { event.preventDefault(); const feature = this.closest(‘.feature’); const longDesc = feature.querySelector(‘.long-desc’); const shortDesc = feature.querySelector(‘.short-desc’); if (longDesc.style.display === “none”) { longDesc.style.display…Continue reading
/* Ajout de Ninja Tables */ .footable .open>.dropdown-menu { display: block !important; } .footable .dropdown-menu{ display: none !important; } .container { overflow: initial !important; } .post-page-numbers { border: 1px solid rgb(0 0 0); padding: 5px 10px; border-radius: 5px; }Continue reading
@property –nat-li-icon { syntax: ““; inherits: false; initial-value: disc; } @property –nat-bgcolor { syntax: ““; inherits: false; initial-value: white; } @property –nat-color { syntax: ““; inherits: false; initial-value: black; } /* Pour les listes */ .nat-li-tkome {–nat-li-icon:”※ “;} .nat-li-tnote {–nat-li-icon:”Note…Continue reading
/* Formattage des images */ img.natha { vertical-align: baseline;} .nath-text-top { vertical-align: text-top; } .nath-align-text-bottom { vertical-align: text-bottom; } .nath-align-sub { vertical-align: sub; } .nath-align-super { vertical-align: super; } .nath-size-square-50px { height : 50px; } .nath-img120par80 { height: 120px; width:…Continue reading
add_action(‘wp_footer’, ‘send_all_datalayer_events_to_clarity’); function send_all_datalayer_events_to_clarity() { ?>Continue reading