AIOSEO FAQ Block accordion

;(() => { const accordionItems = document.querySelectorAll(“.wp-block-aioseo-faq”); if (!accordionItems.length) { return; } accordionItems.forEach((item) => { const itemSummary = item.querySelector(“.aioseo-faq-block-question”); const itemContent = item.querySelector(“.aioseo-faq-block-answer”); itemSummary?.addEventListener(“click”, () => { itemContent?.style.setProperty( “–content-height”, `${itemContent.scrollHeight}px` ); item.classList.toggle(“is-open”); }); }); const faqStyles = ` .wp-block-aioseo-faq {…Continue reading

Custom Default Avatar

/** * IMPORTANT: After activating this snippet you have to change the default avatar option in Settings » Discussion to “Custom Avatar” as defined below. */ add_filter( ‘avatar_defaults’, function( $avatar_defaults ) { $new_avatar_url = ‘https://wpcode.com/wp-content/uploads/2024/09/wpcode-avatar.png’; // Replace this with your…Continue reading