1 // jQuery(function ($) { 2 // // Wait for the document to be ready 3 4 // // When the form is submitted 5 // $('form.wpcf7-form').submit(function (e) { 6 // // Prevent the default form submission 7 // e.preventDefault(); 8 9 // // Your custom validation logic here 10 // var isValid = validateForm(); // Implement your own validation function 11 12 // // If the form is valid, submit the form 13 // if (isValid) { 14 // // Submit the form (non-AJAX) 15 // this.submit(); 16 // } 17 // }); 18 19 // // Your custom validation function 20 // function validateForm() { 21 // // Clear previous error messages 22 // $('.error-message').remove(); 23 24 // // Implement your validation logic here 25 // // Return true if the form is valid, false otherwise 26 // // For example, you can check the values of input fields 27 // var name = $('input[name="your-name"]').val(); 28 // var email = $('input[name="your-email"]').val(); 29 // var message = $('textarea[name="your-message"]').val(); 30 31 // var isValid = true; 32 33 // if (name === '') { 34 // displayErrorMessage('your-name', 'Please enter your name'); 35 // isValid = false; 36 // } 37 38 // if (email === '') { 39 // displayErrorMessage('your-email', 'Please enter your email'); 40 // isValid = false; 41 // } else if (!isValidEmail(email)) { 42 // displayErrorMessage('your-email', 'Please enter a valid email address'); 43 // isValid = false; 44 // } 45 46 // if (message === '') { 47 // displayErrorMessage('your-message', 'Please enter your message'); 48 // isValid = false; 49 // } 50 51 // // Additional validation logic can be added as needed 52 53 // return isValid; // Form is valid 54 // } 55 56 // // Display error messages 57 // function displayErrorMessage(fieldName, message) { 58 // // Create and append an error message element 59 // $('<p class="error-message">' + message + '</p>').insertAfter('[name="' + fieldName + '"]'); 60 // } 61 62 // // Validate email format 63 // function isValidEmail(email) { 64 // // Implement your email validation logic 65 // // For simplicity, this example uses a basic email pattern 66 // var emailPattern = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; 67 // return emailPattern.test(email); 68 // } 69 // }); 70 71 72 73 jQuery(function ($) { 74 75 $('#menu_main > li:not(.sub-menu)').addClass('main-menu-li'); 76 77 $('#menu_main .main-menu-li a.sf-with-ul').addClass('main-anchor'); 78 79 $('#menu_main .main-menu-li').each(function () { 80 if ($(this).find('.sub-menu').length > 0) { 81 var downArrowImg = $('<img src="/wp-content/themes/invetex-child/custom_assets/images/dropdown.svg" alt="Down Arrow">'); // Update the src attribute to the path of your image 82 downArrowImg.css({ 83 'display': 'flex', 84 'align-items': 'center', 85 'margin-left': '5px', 86 'width': '19.4px', // Set the width of the image as needed 87 'height': 'auto', // Adjust height automatically based on the width to maintain aspect ratio 88 'transition': 'transform 0.5s ease' 89 }); 90 $(this).children('a').append(downArrowImg); 91 92 // Hover effect 93 $(this).hover( 94 function () { 95 $(this).addClass('sfHover'); 96 var downArrowImg = $(this).find('img[alt="Down Arrow"]'); 97 downArrowImg.addClass('rotate-arrow'); 98 downArrowImg.css({ 99 'transform': 'rotate(180deg)', 100 'transition': 'transform 0.3s ease' 101 }); 102 }, 103 function () { 104 $(this).removeClass('sfHover'); 105 var downArrowImg = $(this).find('img[alt="Down Arrow"]'); 106 downArrowImg.removeClass('rotate-arrow'); 107 downArrowImg.css({ 108 'transform': 'rotate(0deg)', 109 'transition': 'transform 0.5s ease' 110 }); 111 } 112 ); 113 } 114 }); 115 });
116 117 118 jQuery(function ($) { 119 // Document ready function 120 $(document).ready(function () { 121 // Get all <p> elements within .single-post 122 var paragraphs = $('.single-post p'); 123 124 // Loop through each paragraph and hide if it contains <p> </p> 125 paragraphs.each(function () { 126 if ($(this).html().trim() === ' ') { 127 $(this).hide(); 128 } 129 }); 130 }); 131 }); 132 133 jQuery(function ($) { 134 // Check if .personal-course exists 135 if ($('.personal-course').length > 0) { 136 // Function to create arrows and attach event handlers 137 function addScrollArrows() { 138 $('.elementor-tabs').each(function () { 139 var $thisTabs = $(this); 140 var $tabWrapper = $thisTabs.find('.elementor-tabs-wrapper'); 141 142 // Create left and right arrow elements 143 var $leftArrow = $('<div class="scroll-arrow left-arrow"><</div>'); 144 var $rightArrow = $('<div class="scroll-arrow right-arrow">></div>'); 145 146 // Append arrows to the tabs element, next to the wrapper 147 $tabWrapper.before($leftArrow); 148 $tabWrapper.after($rightArrow); 149 150 // Attach click event for left arrow 151 $leftArrow.click(function() { 152 $tabWrapper.animate({ 153 scrollLeft: '-=200' 154 }, 300); 155 }); 156 157 // Attach click event for right arrow 158 $rightArrow.click(function() { 159 $tabWrapper.animate({ 160 scrollLeft: '+=200' 161 }, 300); 162 }); 163 }); 164 } 165 166 // Function to toggle arrow visibility based on screen width 167 function toggleArrowVisibility() { 168 var screenWidth = $(window).width(); 169 if (screenWidth > 767) { 170 $('.scroll-arrow').hide(); // Hide arrows on larger screens 171 } else { 172 $('.scroll-arrow').show(); // Show arrows on smaller screens 173 } 174 } 175 176 // Call the function to add arrows 177 addScrollArrows(); 178 179 // Initial check for the screen width 180 toggleArrowVisibility(); 181 182 // Recheck when window is resized 183 $(window).resize(function() { 184 toggleArrowVisibility(); 185 }); 186 } 187 }); 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.