Location: site_wide_footer
Floating Chatbot Integration with ChatGPT
wp_enqueue_script( ‘chatbot-float-script’, ‘https://example.com/chatbot-float.js’, array(), ‘1.0.0’, true ); function display_chatbot() { echo ‘ ‘; } add_action( ‘wp_footer’, ‘display_chatbot’ );Continue reading
Cytoscape Disease
document.addEventListener(‘DOMContentLoaded’, () => { //////////////////////////////////////////////////////////////////////////////// // 1) DEFINE NODES & EDGES //////////////////////////////////////////////////////////////////////////////// const elements = [ // === Core (larger) === { data: { id: ‘cardio’, label: ‘Cardiovascular Disease (CAD)’, color: ‘#FF3C38’, // Vermillion textColor: ‘#fff’, fontWeight: ‘600’ }, classes:…Continue reading
ADA Set aria-hidden to divi icons (et-pb-icon)
jQuery( document ).ready( function($) { $(‘.et-pb-icon’).attr(‘aria-hidden’, ‘true’); });Continue reading
Lenis Smooth scroll JS
(cloud) Jony – Scroll on mobile sticky section
document.addEventListener(‘DOMContentLoaded’, function() { const stBottom = document.getElementById(‘st-bottom’); const header = document.querySelector(‘header’); // Adjust the selector if needed const headerHeight = header ? header.offsetHeight : 100; // Fallback height let lastScrollY = window.scrollY; //this is a comment (2) window.addEventListener(‘scroll’, function() {…Continue reading
Newsletter Notice
Subscribe Now to Receive Valuable Travel Tips and Receive Your FREE Guide: 25 Must-Do Artsy Traveler Experiences in Europe for 2025Continue reading
JS WCAG: Kadence dark mode toggle
// get elements by class name const darkModeToggles = document.getElementsByClassName( ‘kadence-color-palette-non-fixed-switcher’ ); // check if dark mode toggles exist if ( darkModeToggles.length > 0 ) { const checkAria = (darkModeToggle) => { // check if body has class .color-switch-dark if…Continue reading
mailpoet close css
/* 弹窗的基本样式 */ .mp_form_popup1 { transition: all 0.3s ease; /* 为弹窗的过渡动画添加平滑效果 */ position: fixed; bottom: 20px; /* 放置在屏幕底部 */ right: 20px; /* 放置在屏幕右侧 */ z-index: 9999; width: 300px; height: 400px; background-color: #fff; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);…Continue reading