Introduction to Ergo Auditor

Ergo Auditor is a comprehensive mobile application developed exclusively for the safety officers of Ergonomia. This innovative tool enables seamless management of safety inspections across various locations while ensuring timely, accurate, and efficient audits.

ChicMic Studios

Initial Challenges in Development

During the development of Ergo Auditor, several challenges surfaced that required tailored solutions to meet the unique needs of safety officers. These challenges spanned from app optimization to robust logic implementation and user experience refinement, reflecting the complexity of the project.

App optimization

Managing significant amounts of data stored locally on the mobile device required a focus on efficient data handling and memory usage. Ensuring quick loading times and a smooth user experience was essential to meet the demands of safety officers working in the field.

#

Logic Implementation

The app required a robust and scalable backend system supported by efficient logic. This meant developing clear and concise algorithms capable of handling dynamic user data and offering reliable performance under various conditions.

#

User Experience

Given the nature of the app, ensuring a user-friendly interface was paramount. The design needed to offer simplicity and clarity, allowing safety officers to navigate the app with ease and access critical features without unnecessary complexity.

#

Cross-Platform Compatibility

Ensuring seamless functionality and a consistent user experience across both iOS and Android devices was critical to broadening the app’s accessibility.

#
ChicMic Studios
Logo

Our Approach to Problem-Solving

To address the challenges, our team employed a meticulous approach that combined cutting-edge technology, rigorous testing, and user-focused design principles. Each solution was crafted to address immediate needs while laying a strong foundation for future scalability.

  • Performance Optimization

    By leveraging Realm DB, we optimized local data storage to ensure efficient offline access and quick data retrieval. We minimized loading times and streamlined data handling, resulting in smooth operations even with large datasets.

  • Robust Logic Implementation

    High-quality algorithms were developed to handle data-intensive tasks with ease. Our team ensured concise code, efficient workflows, and a strong backend system for flawless execution.

  • User-Centric Design

    Extensive prototyping and usability testing were conducted to create an intuitive layout. Key features like clear navigation paths, contextual menus, and responsive design elements were incorporated to enhance the user experience.

  • Cross-Platform Compatibility

    We utilized React Native for consistent functionality across iOS and Android platforms. This ensured that safety officers experienced uniform performance and usability, regardless of their device.

  • Backend Synchronization

    Collaboration with backend developers enabled real-time data synchronization, ensuring safety officers had up-to-date information at their fingertips.

Outstanding Features of Ergo Auditor

Our commitment to user satisfaction led us to design innovative features that enhance functionality and user engagement:

  • portfolio-grid-banner
    Visit Management

    The app organizes safety visits into past, present, and future categories, allowing officers to plan their schedules and prioritize tasks effectively.

  • portfolio-grid-banner
    Issue Reporting

    During inspections, safety officers can report hazards such as missing safety equipment or structural concerns directly through the app, providing detailed descriptions and attaching images for context

  • portfolio-grid-banner
    Issue Tracking

    Officers can update the status of previously reported issues, add comments, and include additional evidence, ensuring thorough follow-ups and improved resolution rates.

  • portfolio-grid-banner
    Data Synchronization

    The app synchronizes with the backend server to fetch the latest data and ensure consistency across all devices. This feature is especially critical for maintaining accurate records and effective collaboration among safety teams.

portfolio-feature

Services Delivered

Developing Ergo Auditor demanded creativity, technical expertise, and an outside-the-box approach. Our team provided the following services to craft a world-class app:

ui-ux services
Mobile App Development
Project services
Project Management
Deploy services
Deployment
ui-ux services
Quality Assurance
ChicMic Studios

Key Project Milestones

The development of Ergo Auditor was completed in a series of well-defined milestones, ensuring a systematic and efficient approach.

Requirement Gathering

Collaborating with the Ergo Auditor team to define objectives and goals.

Duration:

2-3 days

Team Members

Business Analyst and QA

App Development

Building core features and functionalities while adhering to deadlines.

Duration:

15-20 days

Team Members

UI & UX Designers,BA

App Testing

Conducting rigorous testing to ensure a bug-free and user-friendly app.

Duration:

2-3 days

Team Members

Bar Code

Technology Stack

We utilized a modern and versatile technology stack to ensure Ergo Auditor offers a seamless, high-performance user experience. By combining innovative front-end and back-end technologies, we created a scalable and reliable solution tailored to user needs.

iOS Development

Crafted an innovative solution for Apple devices with cutting-edge tools.

  • Xcode
  • React Native

Android Development

Building core features and functionalities while adhering to deadlines.

  • Android Studio

Backend Development

Built a strong backend infrastructure to support app functionality.

  • Particle Auth SDK

Quality Assurance

Ensuring a flawless app experience with comprehensive testing processes.

  • Selenium

Final Outcome

Ergo Auditor has redefined safety inspection processes for Ergonomia. By equipping safety officers with a powerful and intuitive tool, the app ensures comprehensive management of safety visits, precise issue reporting, and effective resolution tracking. With real-time synchronization and robust offline capabilities, Ergo Auditor empowers officers to maintain high safety standards while improving operational efficiency.

Create a business value with every App

Why Not Kickoff Your Dream Project With Us? Schedule a Call

ChicMic Studios
landing
Requirement

About The Client

More case studies

',!event.target.classList.contains('.ems')) $(".menu-menu-1-container").removeClass("active"); } }) $(".events-pics li a").addClass("stupidbox"); $('.lightgallery')?.lightGallery(); $('.lightgallery-51')?.lightGallery(); $('.lightgallery-52')?.lightGallery(); $('.lightgallery-53')?.lightGallery(); $('.lightgallery-62')?.lightGallery(); $('.lightgallery-270')?.lightGallery(); /* if ($('.lightgallery').length) { $('.lightgallery').lightGallery(); } else { console.log("lightGallery class does not exist."); } */ // }); // Sub Menu $('body').on('click', '.menu-item:not(.mega_menu_btn)', function() { // $('.menu-item').removeClass('current-active'); $(this).toggleClass('current-active'); }); /* jQuery(function ($) { $(".events-pics li a").stupidbox(); }); */ jQuery(function($) { // if ($.fn.stupidbox) { $(".events-pics li a").stupidbox(); // } else { // console.error("stupidbox plugin is not available."); // } }); /* jQuery(document).ready(function($) { $(".events-pics li a").stupidbox(); }); */ function testInput(event) { var value = String.fromCharCode(event.which); var pattern = new RegExp(/[a-zåäö ]/i); return pattern.test(value); } $cf = $('[name="Tel"], [name="tel-264"]'); $cf.keypress(function(evt) { evt = (evt) ? evt : window.event; var charCode = (evt.which) ? evt.which : evt.keyCode; if (charCode > 31 && (charCode < 48 || charCode > 57)) { return false; } return true; }); // $(document).ready(function () { $('[name="text-340"], [name="text-590"]').bind('keypress change', testInput); // }); } catch (exception) {} //gtag('event', 'conversion', { // 'send_to': 'AW-303605633/haqpCIyzvv0CEIHP4pAB' //}); try { function initSlick() { try { // $('.responsive').slick({ dots: false, arrows: false, infinite: false, speed: 300, autoplay: true, slidesToShow: 2, slidesToScroll: 2, responsive: [{ breakpoint: 1024, settings: { slidesToShow: 2, slidesToScroll: 2, infinite: true, } }, { breakpoint: 600, settings: { slidesToShow: 2, slidesToScroll: 2 } }, { breakpoint: 480, settings: { slidesToShow: 1, slidesToScroll: 1 } } ] }); // Game development $('.slider-for').slick({ slidesToShow: 1, slidesToScroll: 1, arrows: false, fade: true, autoplay: true, autoplaySpeed: 5000, asNavFor: '.slider-nav' }); $('.slider-nav').slick({ slidesToShow: 10, // slidesToScroll: 1, Horizontal: true, asNavFor: '.slider-for', dots: false, arrow: false, focusOnSelect: true, HorizontalSwiping: true, // infinite:true, responsive: [{ breakpoint: 1400, settings: { vertical: false, slidesToShow: 5, } }, { breakpoint: 1199, settings: { vertical: false, slidesToShow: 5, } }, { breakpoint: 768, settings: { vertical: false, slidesToShow: 3, } }, { breakpoint: 580, settings: { vertical: false, slidesToShow: 2, } } ] }); // Banner Slider $('.slider-for_1').slick({ slidesToShow: 1, slidesToScroll: 1, arrows: false, fade: true, autoplay: true, autoplaySpeed: 5000, asNavFor: '.slider-nav_1' }); $('.slider-nav_1').slick({ slidesToShow: 6, // slidesToScroll: 1, Horizontal: true, asNavFor: '.slider-for_1', dots: false, arrow: false, focusOnSelect: true, HorizontalSwiping: false, // infinite:true, responsive: [{ breakpoint: 1200, settings: { vertical: false, slidesToShow: 5, } }, { breakpoint: 768, settings: { vertical: false, slidesToShow: 3, } }, { breakpoint: 575, settings: { vertical: false, slidesToShow: 2, } } ] }); //home page slider $('#logo_slider').slick({ lazyLoad: 'ondemand', dots: false, infinite: true, autoplay: true, loop: true, autoplaySpeed: 0, speed: 3000, slidesToShow: 6, cssEase: 'linear', arrows: 'false', drag: false, pauseOnHover: false, draggable: false, swipe: false, responsive: [{ breakpoint: 1024, settings: { slidesToShow: 3, slidesToScroll: 1, infinite: true, } }, { breakpoint: 600, settings: { slidesToShow: 3, slidesToScroll: 1 } }, { breakpoint: 480, settings: { slidesToShow: 2.5, slidesToScroll: 1 } } ] }); // Slick slider Banner $('.slider').not('.slick-initialized').slick({ dots: false, arrows: false, infinite: true, slidesToShow: 1, slidesToScroll: 1, fade: true, autoplay: true, speed: 1000, //cssEase: 'linear', pauseOnHover: false, responsive: [{ breakpoint: 767, settings: { arrows: false, slidesToShow: 1, slidesToScroll: 1 } }] }); if ($('.testimonial_group').length) { // Android page Testimonial sldier $('.testimonial_group').slick({ dots: false, infinite: true, autoplay: true, speed: 500, slidesToShow: 3, slidesToScroll: 1, arrows: true, pauseOnHover: true, draggable: true, centerMode: false, responsive: [{ breakpoint: 991, settings: { slidesToShow: 2, slidesToScroll: 1, } }, { breakpoint: 767, settings: { slidesToShow: 1, slidesToScroll: 1, } }, ] }); } } catch (exception) {} } // $(document).ready(setTimeout(() => initSlick(), 1500)); // $(document).ready(function () { // Initialize slick // initSlick(); // initializeSlick(); // },500); //for your requirements checkboxes ui jQuery('.Checkboxx').on('change', function() { jQuery('#page_option').val(''); console.log(jQuery('.Checkboxx:checked').map(function() { return this.value; }).get().join(', ')); var options2 = jQuery('.Checkboxx:checked').map(function() { return this.value; }).get().join(', '); jQuery('#page_options').val(options2); }); } catch (e) {} /* For modal popup global */ var countryinput = document.querySelector("#phone"); if (typeof countryinput !== 'undefined' && countryinput !== null) { var countryiti = window.intlTelInput(countryinput, { initialCountry: "auto", utilsScript: "https://cdn.jsdelivr.net/npm/intl-tel-input@18.1.1/build/js/utils.js", geoIpLookup: function(callback) { fetch("https://ipapi.co/json") .then(function(res) { return res.json(); }) .then(function(data) { callback(data.country_code); }) .catch(function() { callback("us"); }); }, showFlags: true, nationalMode: false, separateDialCode: true, }); // countryiti.setCountry("in"); $("#phone").on("countrychange", function($e) { // var SelectedCountry = countryiti.getSelectedCountryData(); var countryCode = $("#front_get_started .modal-content .modal-body").find(".iti__selected-dial-code") .html(); $("#country_code").val(countryCode); }); } // removed from here // Validate form $(document).on('submit', '#front_form_get_started', function(event) { event.preventDefault(); // country_code = $("#country_code").val().trim(), let name = $("#name").val().trim(), email = $("#email").val().trim(), phone = $("#phone").val().trim(), descmessage = $("#message_2").val().trim(); // let descmessage = document.getElementById('message_2').value; const regex = /^[A-Za-z\s]+$/; const email_regex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; const country_code_regex = /^[A-Za-z]+$/; const phone_digit_pattern = /^\d+$/; const phone_digit_length = /^[0-9]{9,13}$/; const message_allowed = /^(?!\d+$)(?:[a-zA-Z0-9][a-zA-Z0-9 @&$]*)?$/; if (name == "" || name == " ") { $("#name_error").html("Please enter name"); $("#name").val(name); $("#name").focus(); return false; } else if (!regex.test(name)) { // if valid will return regex.test(name) // $("#name_error").html("Please enter letters with white space only"); $("#name_error").html("Only alphabets and spaces are allowed."); $("#name").val(name); return false; } else if (name.length > 100) { // if valid will return regex.test(name) true $("#name_error").html("Only 100 letters with white space are allowed"); $("#name").val(name); return false; } else { $("#name").val(name); $("#name_error").html(""); } if (email == "" || email == " ") { $("#email_error").html("Please enter an email"); $("#email").val(email); $("#email").focus(); return false; } else if (!email_regex.test(email)) { $("#email_error").html("Please enter a valid email"); $("#email").val(email); $("#email").focus(); return false; } else { $("#email_error").html(""); } if (phone == "" || phone == " ") { $("#phone_error").html("Phone is required"); $("#phone").val(phone); $("#phone").focus(); return false; } else if (phone.startsWith("0")) { $("#phone_error").html("Phone number cannot start with 0."); $("#phone").val(phone); $("#phone").focus(); return false; } else if (!phone_digit_pattern.test(phone)) { $("#phone_error").html("Phone only digit are allowed"); $("#phone").val(phone); $("#phone").focus(); return false; } else if (!phone_digit_length.test(phone)) { $("#phone_error").html("Phone between 9 and 13 digits in total are allowed"); $("#phone").val(phone); $("#phone").focus(); return false; } else { $("#phone_error").html(""); } // if($('#g-recaptcha-response-1').val() == '') { var recaptchaResponse = grecaptcha.getResponse(g_recaptcha); // var recaptchaResponse = grecaptcha.getResponse(); if (recaptchaResponse == "") { $("#recaptcha_error").html("Please complete the reCAPTCHA challenge."); return false; } else { $("#recaptcha_error").html(""); } var submit_loader = document.querySelector(".submit_loader"); submit_loader.style.display = "block"; var form = $("#front_form_get_started"); var formData = form.serialize(); $.ajax({ type: "POST", url: "https://www.chicmicstudios.in/wp-content/themes/chicmic/send_email.php", data: formData, success: function(response) { submit_loader.style.display = "none"; grecaptcha.reset(); if (response.trim() == "SUCCESS") { $(".global_success").html( '' ); setTimeout(function() { $(".global_success").html(""); $(".close_form").trigger("click"); window.location.href = "https://www.chicmicstudios.in/thank-you/"; }, 3000); $("#name_error").html(""); $("#email_error").html(""); $("#phone_error").html(""); $("#message_error").html(""); $("#front_form_get_started")[0].reset(); $("#front_form_get_started").trigger("reset"); } else if (response == "FAIL") { $(".global_error").html( '' ); setTimeout(function() { $(".global_error").html(""); }, 5000); } else { $(".global_error").html( '" ); setTimeout(function() { $(".global_error").html(""); }, 5000); } }, error: function(error) { submit_loader.style.display = "none"; grecaptcha.reset(); $(".global_success").html(""); $("#name_error").html(""); $("#email_error").html(""); $("#phone_error").html(""); $("#message_error").html(""); $("#front_form_get_started")[0].reset(); $("#front_form_get_started").trigger("reset"); $("#global_error").html( "There is some issue in sending email. Please try after sometime." ); }, }); return false; }); function validateForm(event) { // country_code = $("#country_code").val().trim(), let name = $("#name").val().trim(), email = $("#email").val().trim(), phone = $("#phone").val().trim(), descmessage = $("#message_2").val().trim(); // let descmessage = document.getElementById('message_2').value; const regex = /^[A-Za-z\s]+$/; const email_regex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; const country_code_regex = /^[A-Za-z]+$/; const phone_digit_pattern = /^\d+$/; const phone_digit_length = /^[0-9]{9,13}$/; const message_allowed = /^(?!\d+$)(?:[a-zA-Z0-9][a-zA-Z0-9 @&$]*)?$/; if (name == "" || name == " ") { $("#name_error").html("Please enter name"); $("#name").val(name); $("#name").focus(); return false; } else if (!regex.test(name)) { // if valid will return regex.test(name) // $("#name_error").html("Please enter letters with white space only"); $("#name_error").html("Only alphabets and spaces are allowed."); $("#name").val(name); return false; } else if (name.length > 100) { // if valid will return regex.test(name) true $("#name_error").html("Only 100 letters with white space are allowed"); $("#name").val(name); return false; } else { $("#name").val(name); $("#name_error").html(""); } if (email == "" || email == " ") { $("#email_error").html("Please enter an email"); $("#email").val(email); $("#email").focus(); return false; } else if (!email_regex.test(email)) { $("#email_error").html("Please enter a valid email"); $("#email").val(email); $("#email").focus(); return false; } else { $("#email_error").html(""); } if (phone == "" || phone == " ") { $("#phone_error").html("Phone is required"); $("#phone").val(phone); $("#phone").focus(); return false; } else if (phone.startsWith('0')) { $("#phone_error").html("Phone number cannot start with 0."); $("#phone").val(phone); $("#phone").focus(); return false; } else if (!phone_digit_pattern.test(phone)) { $("#phone_error").html("Phone only digit are allowed"); $("#phone").val(phone); $("#phone").focus(); return false; } else if (!phone_digit_length.test(phone)) { $("#phone_error").html("Phone between 9 and 13 digits in total are allowed"); $("#phone").val(phone); $("#phone").focus(); return false; } else { $("#phone_error").html(""); } // if($('#g-recaptcha-response-1').val() == '') { var recaptchaResponse = grecaptcha.getResponse(g_recaptcha); // var recaptchaResponse = grecaptcha.getResponse(); if (recaptchaResponse == '') { $("#recaptcha_error").html("Please complete the reCAPTCHA challenge."); return false; } else { $("#recaptcha_error").html(""); } var submit_loader = document.querySelector('.submit_loader'); submit_loader.style.display = 'block'; var form = $('#front_form_get_started'); var formData = form.serialize(); $.ajax({ type: 'POST', url: "https://www.chicmicstudios.in/wp-content/themes/chicmic/send_email.php", data: formData, success: function(response) { submit_loader.style.display = 'none'; grecaptcha.reset(); if (response.trim() == "SUCCESS") { $(".global_success").html( '' ); setTimeout(function() { $(".global_success").html(''); $('.close_form').trigger('click'); window.location.href = "https://www.chicmicstudios.in/thank-you/"; }, 3000); $("#name_error").html(""); $("#email_error").html(""); $("#phone_error").html(""); $("#message_error").html(""); $("#front_form_get_started")[0].reset(); $("#front_form_get_started").trigger('reset'); } else if (response == "FAIL") { $(".global_error").html( '' ); setTimeout(function() { $(".global_error").html(''); }, 5000); } else { $(".global_error").html(''); setTimeout(function() { $(".global_error").html(''); }, 5000); } }, error: function(error) { submit_loader.style.display = 'none'; grecaptcha.reset(); $(".global_success").html(""); $("#name_error").html(""); $("#email_error").html(""); $("#phone_error").html(""); $("#message_error").html(""); $("#front_form_get_started")[0].reset(); $("#front_form_get_started").trigger('reset'); $("#global_error").html("There is some issue in sending email. Please try after sometime."); } }); return false; } $('#front_get_started').on('hidden.bs.modal', function() { grecaptcha.reset(); $("#name_error").html(""); $("#email_error").html(""); $("#phone_error").html(""); $("#message_error").html(""); $("#front_form_get_started")[0].reset(); $(this).find('form').trigger('reset'); }); /* For modal popup global end */ var innercountryinput = document.querySelector("#phone_1"); if (typeof innercountryinput !== 'undefined' && innercountryinput !== null) { var innercountryiti = window.intlTelInput(innercountryinput, { initialCountry: "auto", utilsScript: "https://cdn.jsdelivr.net/npm/intl-tel-input@18.1.1/build/js/utils.js", geoIpLookup: function(callback) { fetch("https://ipapi.co/json") .then(function(res) { return res.json(); }) .then(function(data) { callback(data.country_code); }) .catch(function() { callback("us"); }); }, showFlags: true, nationalMode: false, separateDialCode: true, }); // countryiti.setCountry("in"); $("#phone_1").on("countrychange", function($e) { // var SelectedCountry = countryiti.getSelectedCountryData(); var countryCode = $("#inner_form_get_started").find(".iti__selected-dial-code").html(); $("#country_code_1").val(countryCode); }); } // message us form $(document).on('submit', '#inner_form_get_started', function(event) { event.preventDefault(); // alert('submit message form'); // country_code = $("#country_code").val().trim(), let name_1 = $("#name_1").val().trim(), email_1 = $("#email_1").val().trim(), phone_1 = $("#phone_1").val().trim(), message_1 = $("#message_1").val().trim(); let descmessage = $("#message_1").html().trim(); const regex = /^[A-Za-z\s]+$/; const email_regex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; const country_code_regex = /^[A-Za-z]+$/; const phone_digit_pattern = /^\d+$/; const phone_digit_length = /^[0-9]{9,13}$/; if (name_1 == "" || name_1 == " ") { $("#name_1_error").html("Please enter name"); $("#name_1").val(name_1); $("#name_1").focus(); return false; } else if (!regex.test(name_1)) { // if valid will return regex.test(name) $("#name_1_error").html("Only alphabets and spaces are allowed."); // $("#name_1_error").html("Please enter letters with white space only"); $("#name_1").val(name_1); return false; } else if (name_1.length > 100) { // if valid will return regex.test(name) true $("#name_1_error").html("Only 100 letters with white space are allowed"); $("#name_1").val(name_1); return false; } else { $("#name_1").val(name_1); $("#name_1_error").html(""); } if (email_1 == "" || email_1 == " ") { $("#email_1_error").html("Please enter an email"); $("#email_1").val(email_1); $("#email_1").focus(); return false; } else if (!email_regex.test(email_1)) { $("#email_1_error").html("Please enter a valid email"); $("#email_1").val(email_1); $("#email_1").focus(); return false; } else { $("#email_1_error").html(""); } if (phone_1 == "" || phone_1 == " ") { $("#phone_1_error").html("Phone is required"); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else if (phone_1.startsWith('0')) { $("#phone_1_error").html("Phone number cannot start with 0."); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else if (!phone_digit_pattern.test(phone_1)) { $("#phone_1_error").html("Phone only digit are allowed"); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else if (!phone_digit_pattern.test(phone_1)) { $("#phone_1_error").html("Phone only digit are allowed"); $("#phone_1").val(phone); $("#phone_1").focus(); return false; } else if (!phone_digit_length.test(phone_1)) { $("#phone_1_error").html("Phone between 9 and 13 digits in total are allowed"); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else { $("#phone_1_error").html(""); } // var recaptchaResponse = grecaptcha.getResponse(recaptcha_id); // var response = grecaptcha.getResponse(); if ($('#g-recaptcha-response-1').val() == '') { $("#recaptcha_1_error").html("Please complete the reCAPTCHA challenge."); return false; } else { $("#recaptcha_1_error").html(""); } var submit_loader = document.querySelector('.submit_form_loader'); submit_loader.style.display = 'block'; var form = $('#inner_form_get_started'); var formData = form.serialize(); $.ajax({ type: 'POST', url: "https://www.chicmicstudios.in/wp-content/themes/chicmic/send_email.php", data: formData, success: function(response) { submit_loader.style.display = 'none'; resetRecaptcha2(); // grecaptcha.reset(); if (response.trim() == "SUCCESS") { $("#inner_form_success").show(); $("#inner_form_success").html( "Thank you for contacting us. We are assessing your query and get back to you soon." ); setTimeout(function() { $("#inner_form_success").hide(); window.location.href = "https://www.chicmicstudios.in/thank-you/"; }, 3000); $("#name_1_error").html(""); $("#email_1_error").html(""); $("#phone_1_error").html(""); $("#message_1_error").html(""); $("#inner_form_get_started")[0].reset(); $("#inner_form_get_started").trigger('reset'); } else if (response == "FAIL") { $(".global_error_1").html( '' ); setTimeout(function() { $(".global_error_1").html(''); }, 5000); } else { $(".global_error_1").html(''); setTimeout(function() { $(".global_error_1").html(''); }, 5000); } }, error: function(error) { resetRecaptcha2(); submit_loader.style.display = 'none'; // grecaptcha.reset(); $("#global_error_1").html("There is some issue in sending email. Please try after sometime."); } }); return false; }); // Validate form function validateInnerForm() { // country_code = $("#country_code").val().trim(), let name_1 = $("#name_1").val().trim(), email_1 = $("#email_1").val().trim(), phone_1 = $("#phone_1").val().trim(), message_1 = $("#message_1").val().trim(); let descmessage = $("#message_1").html().trim(); const regex = /^[A-Za-z\s]+$/; const email_regex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; const country_code_regex = /^[A-Za-z]+$/; const phone_digit_pattern = /^\d+$/; const phone_digit_length = /^[0-9]{9,13}$/; if (name_1 == "" || name_1 == " ") { $("#name_1_error").html("Please enter name"); $("#name_1").val(name_1); $("#name_1").focus(); return false; } else if (!regex.test(name_1)) { // if valid will return regex.test(name) $("#name_1_error").html("Only alphabets and spaces are allowed."); // $("#name_1_error").html("Please enter letters with white space only"); $("#name_1").val(name_1); return false; } else if (name_1.length > 100) { // if valid will return regex.test(name) true $("#name_1_error").html("Only 100 letters with white space are allowed"); $("#name_1").val(name_1); return false; } else { $("#name_1").val(name_1); $("#name_1_error").html(""); } if (email_1 == "" || email_1 == " ") { $("#email_1_error").html("Please enter an email"); $("#email_1").val(email_1); $("#email_1").focus(); return false; } else if (!email_regex.test(email_1)) { $("#email_1_error").html("Please enter a valid email"); $("#email_1").val(email_1); $("#email_1").focus(); return false; } else { $("#email_1_error").html(""); } if (phone_1 == "" || phone_1 == " ") { $("#phone_1_error").html("Phone is required"); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else if (phone_1.startsWith('0')) { $("#phone_1_error").html("Phone number cannot start with 0."); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else if (!phone_digit_pattern.test(phone_1)) { $("#phone_1_error").html("Phone only digit are allowed"); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else if (!phone_digit_pattern.test(phone_1)) { $("#phone_1_error").html("Phone only digit are allowed"); $("#phone_1").val(phone); $("#phone_1").focus(); return false; } else if (!phone_digit_length.test(phone_1)) { $("#phone_1_error").html("Phone between 9 and 13 digits in total are allowed"); $("#phone_1").val(phone_1); $("#phone_1").focus(); return false; } else { $("#phone_1_error").html(""); } // var recaptchaResponse = grecaptcha.getResponse(recaptcha_id); // var response = grecaptcha.getResponse(); if ($('#g-recaptcha-response-1').val() == '') { $("#recaptcha_1_error").html("Please complete the reCAPTCHA challenge."); return false; } else { $("#recaptcha_1_error").html(""); } var submit_loader = document.querySelector('.submit_form_loader'); submit_loader.style.display = 'block'; var form = $('#inner_form_get_started'); var formData = form.serialize(); $.ajax({ type: 'POST', url: "https://www.chicmicstudios.in/wp-content/themes/chicmic/send_email.php", data: formData, success: function(response) { submit_loader.style.display = 'none'; resetRecaptcha2(); // grecaptcha.reset(); if (response == "SUCCESS") { $("#inner_form_success").show(); $("#inner_form_success").html( "Thank you for contacting us. We are assessing your query and get back to you soon." ); setTimeout(function() { $("#inner_form_success").hide(); }, 5000); $("#name_1_error").html(""); $("#email_1_error").html(""); $("#phone_1_error").html(""); $("#message_1_error").html(""); $("#inner_form_get_started")[0].reset(); $("#inner_form_get_started").trigger('reset'); } else if (response == "FAIL") { $(".global_error_1").html( '' ); setTimeout(function() { $(".global_error_1").html(''); }, 5000); } else { $(".global_error_1").html(''); setTimeout(function() { $(".global_error_1").html(''); }, 5000); } }, error: function(error) { resetRecaptcha2(); submit_loader.style.display = 'none'; // grecaptcha.reset(); $("#global_error_1").html("There is some issue in sending email. Please try after sometime."); } }); return false; } document.addEventListener('DOMContentLoaded', function() { var contactcountryinput = document.querySelector("#phone_2"); if (typeof contactcountryinput !== 'undefined' && contactcountryinput !== null) { var contactcountryiti = window.intlTelInput(contactcountryinput, { initialCountry: "auto", utilsScript: "https://cdn.jsdelivr.net/npm/intl-tel-input@18.1.1/build/js/utils.js", geoIpLookup: function(callback) { fetch("https://ipapi.co/json") .then(function(res) { return res.json(); }) .then(function(data) { callback(data.country_code); }) .catch(function() { callback("us"); }); }, showFlags: true, nationalMode: false, separateDialCode: true, }); } // Your code here // countryiti.setCountry("in"); $("#phone_2").on("countrychange", function($e) { // var SelectedCountry = countryiti.getSelectedCountryData(); var countryCode = $("#page_contact_form").find(".iti__selected-dial-code").html(); $("#country_code_2").val(countryCode); }); }); // Validate contact form function validateContactForm() { // country_code = $("#country_code").val().trim(), let name_2 = $("#name_2").val().trim(), email_2 = $("#email_2").val().trim(), phone_2 = $("#phone_2").val().trim(), message_2 = $("#message_2").val().trim(), category_type = $("#category_type").val().trim(); let descmessage = $("#message_2").html().trim(); const regex = /^[A-Za-z\s]+$/; const email_regex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/; const country_code_regex = /^[A-Za-z]+$/; const phone_digit_pattern = /^\d+$/; const phone_digit_length = /^[0-9]{9,13}$/; if (name_2 == "" || name_2 == " ") { $("#name_2_error").html("Please enter name"); $("#name_2").val(name_2); $("#name_2").focus(); return false; } else if (!regex.test(name_2)) { // if valid will return regex.test(name) $("#name_2_error").html("Only alphabets and spaces are allowed."); // $("#name_2_error").html("Please enter letters with white space only"); $("#name_2").val(name_2); return false; } else if (name_2.length > 100) { // if valid will return regex.test(name) true $("#name_2_error").html("Only 100 letters with white space are allowed"); $("#name_2").val(name_2); return false; } else { $("#name_2").val(name_2); $("#name_2_error").html(""); } if (email_2 == "" || email_2 == " ") { $("#email_2_error").html("Please enter an email"); $("#email_2").val(email_2); $("#email_2").focus(); return false; } else if (!email_regex.test(email_2)) { $("#email_2_error").html("Please enter a valid email"); $("#email_2").val(email_2); $("#email_2").focus(); return false; } else { $("#email_2_error").html(""); } if (phone_2 == "" || phone_2 == " ") { $("#phone_2_error").html("Phone is required"); $("#phone_2").val(phone_2); $("#phone_2").focus(); return false; } else if (phone_2.startsWith('0')) { $("#phone_2_error").html("Phone number cannot start with 0."); $("#phone_2").val(phone_2); $("#phone_2").focus(); return false; } else if (!phone_digit_pattern.test(phone_2)) { $("#phone_2_error").html("Phone only digit are allowed"); $("#phone_2").val(phone_2); $("#phone_2").focus(); return false; } else if (!phone_digit_pattern.test(phone_2)) { $("#phone_2_error").html("Phone only digit are allowed"); $("#phone_2").val(phone_2); $("#phone_2").focus(); return false; } else if (!phone_digit_length.test(phone_2)) { $("#phone_2_error").html("Phone between 9 and 13 digits in total are allowed"); $("#phone_2").val(phone_2); $("#phone_2").focus(); return false; } else { $("#phone_2_error").html(""); } if (category_type == "" || category_type == " ") { $("#category_type_error").html("Empty option from dropdown not allowed"); // $("#category_type").val(phone_2); $("#category_type").focus(); return false; } else if (!regex.test(category_type)) { // if valid will return regex.test(name) $("#category_type_error").html("Only letters with white space options are allowed"); $("#category_type").focus(); return false; } else { $("#category_type_error").html(""); } var form = $('#page_contact_form'); var formData = form.serialize(); $.ajax({ type: 'POST', url: "https://www.chicmicstudios.in/wp-content/themes/chicmic/send_email.php", data: formData, success: function(response) { // console.log(response); if (response == "SUCCESS") { $("#page_contact_form_success").show(); $("#page_contact_form_success").html( "Thank you for contacting us. We are assessing your query and get back to you soon." ); setTimeout(function() { $("#page_contact_form_success").hide(); }, 5000); $("#name_2_error").html(""); $("#email_2_error").html(""); $("#phone_2_error").html(""); $("#message_2_error").html(""); $("#page_contact_form")[0].reset(); $("#page_contact_form").trigger('reset'); } else if (response == "FAIL") { $(".global_error_2").html( '' ); setTimeout(function() { $(".global_error_2").html(''); }, 5000); } else { $(".global_error_2").html(''); setTimeout(function() { $(".global_error_2").html(''); }, 5000); } }, error: function(error) { $("#global_error_1").html("There is some issue in sending email. Please try after sometime."); } }); return false; } // Design portfolio tabs $(document).on('click', '.portfolionavtab.nav-link', function(event) { // console.log(event); let targetId = $(this).attr('href'); // $(this).addClass('active'); $('.tab-pane').hide(); $(targetId).show(); }); var hash = window.location.hash; var sTabHash = hash.split('#tab'); var isTab = sTabHash[1] > 0 ? sTabHash[1] : 0; var tabId = hash.substring(1, hash.length); if (tabId) { $(".nav.nav-tabs li").removeClass("active"); $(".tab-content div[class*=tab-pane]").removeClass("active"); $(".nav.nav-tabs li a[href*=" + tabId + "]").parent().addClass("active"); $("#" + tabId + "").addClass("active"); } else if (tabId) { tabId = '3DCharacterart'; $(".nav.nav-tabs li").removeClass("active"); $(".tab-content div[class*=tab-pane]").removeClass("active"); $(".nav.nav-tabs li a[href*=" + tabId + "]").parent().addClass("active"); $("#" + tabId + "").addClass("active"); } else if (tabId) { tabId = 'all'; $(".nav.nav-tabs li").removeClass("active"); $(".tab-content div[class*=tab-pane]").removeClass("active"); $(".nav.nav-tabs li a[href*=" + tabId + "]").parent().addClass("active"); $("#" + tabId + "").addClass("active"); } // Services Slick slider for Mobile function initMobileView() { // $(document).ready(function () { try { $('#services-slider').slick({ slidesToShow: 1, slidesToScroll: 1, autoplay: true, autoplaySpeed: 2000, responsive: [{ breakpoint: 9999, settings: "unslick" }, { breakpoint: 991, settings: { slidesToShow: 1, slidesToScroll: 1, infinite: true, dots: true, dragable: true, nav: false, autoplay: true, // adaptiveHeight: true, } }, { breakpoint: 575, settings: { slidesToShow: 1, slidesToScroll: 1, infinite: true, dots: true, loop: true, dragable: true, nav: false, arrows: false, autoplay: true, // adaptiveHeight: true, } }, ] }); } catch (exception) {} try { $('#services-slider-nft').slick({ slidesToShow: 1, slidesToScroll: 1, autoplay: true, autoplaySpeed: 2000, responsive: [{ breakpoint: 9999, settings: "unslick" }, { breakpoint: 900, settings: { slidesToShow: 2, slidesToScroll: 1, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, { breakpoint: 575, settings: { slidesToShow: 1, slidesToScroll: 1, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, ] }); } catch (exception) {} try { $('#services-slider-nft_how-we-work').slick({ slidesToShow: 1, slidesToScroll: 1, autoplay: true, autoplaySpeed: 2000, arrows: false, responsive: [{ breakpoint: 9999, settings: "unslick" }, { breakpoint: 900, settings: { arrows: false, slidesToShow: 2, slidesToScroll: 2, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, { breakpoint: 575, settings: { slidesToShow: 1, slidesToScroll: 1, arrows: false, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, ] }); } catch (exception) {} try { $('#services-slider-nft_whychoose').slick({ slidesToShow: 1, slidesToScroll: 1, autoplay: true, autoplaySpeed: 2000, arrows: false, responsive: [{ breakpoint: 9999, settings: "unslick" }, { breakpoint: 900, settings: { arrows: false, slidesToShow: 2, slidesToScroll: 1, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, { breakpoint: 575, settings: { slidesToShow: 1, slidesToScroll: 1, arrows: false, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, ] }); } catch (exception) {} try { $('#services-slider_metaverse').slick({ slidesToShow: 1, slidesToScroll: 1, autoplay: true, autoplaySpeed: 2000, arrows: false, responsive: [{ breakpoint: 9999, settings: "unslick" }, { breakpoint: 900, settings: { arrows: false, slidesToShow: 2, slidesToScroll: 2, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, { breakpoint: 575, settings: { slidesToShow: 1, slidesToScroll: 1, arrows: false, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, ] }); } catch (exception) {} try { $('#services-slider_metaverse-workflow').slick({ slidesToShow: 1, slidesToScroll: 1, autoplay: true, autoplaySpeed: 2000, arrows: false, responsive: [{ breakpoint: 9999, settings: "unslick" }, { breakpoint: 900, settings: "unslick" }, { breakpoint: 575, settings: { slidesToShow: 1, slidesToScroll: 1, arrows: false, infinite: true, dots: true, dragable: true, nav: false, adaptiveHeight: true, } }, ] }); // Mobile Why Choose Slider $('#why_choose_slider').slick({ slidesToShow: 1, slidesToScroll: 1, autoplay: true, autoplaySpeed: 2000, arrows: false, responsive: [{ breakpoint: 9999, settings: "unslick" }, { breakpoint: 900, settings: { slidesToShow: 1, slidesToScroll: 1, infinite: true, dots: true, loop: true, dragable: true, nav: false, arrows: false, adaptiveHeight: true, } }, { breakpoint: 575, settings: { slidesToShow: 1, slidesToScroll: 1, arrows: false, infinite: true, dots: true, dragable: true, nav: false, } }, ] }); // } } catch (exception) {} // }); } // $(document).ready(initMobileView()); initMobileView() // Mobile dropmenu var windowWidth = window.innerWidth; // $(window).resize(function () { function toggleDropdown() { try { // if ($(window).width() < 2000) { var dropdownMenu = document.querySelector('.dropdown-select-menu'); dropdownMenu.style.display = dropdownMenu.style.display === 'block' ? 'none' : 'block'; // } } catch (e) {} } let initDropdowns = () => { try { if ($(window).width()) { //Selection none var dropdownMenu = document.querySelector('.dropdown-select-menu'); dropdownMenu.style.display = 'none'; // Dropdown Mobile var dropdown = document.getElementById('dropdown'); function toggleDropdown() { var dropdownMenu = document.querySelector('.dropdown-select-menu'); dropdownMenu.style.display = dropdownMenu.style.display === 'block' ? 'none' : 'block'; } function updateCount() { var checkboxes = document.querySelectorAll('#dropdown-list input[type="checkbox"]'); var count = 0; checkboxes.forEach(function(checkbox) { if (checkbox.checked) { count++; } }); var selectedCount = document.getElementById('selected-count'); selectedCount.textContent = count + ' items selected'; if (count == 0) { selectedCount.textContent = ' Select Services'; } } document.addEventListener('click', function(event) { var isClickInside = dropdown.contains(event.target); if (!isClickInside) { var dropdownMenu = document.querySelector('.dropdown-select-menu'); dropdownMenu.style.display = 'none'; } }); // }; } // Mobile dropmenu var windowWidth = window.innerWidth; } catch (e) {} } initDropdowns(); // Footer Accordin for Mobile var width = $(document).width(); $('.links_new').first().addClass('active'); // if (width < 900) { $('.links_new').click(function() { // Check if the clicked accordion is already active var isActive = $(this).hasClass('active'); // $('.links_new1:first').show(); // Hide all accordions $('.links_new').removeClass('active'); $('.accordin_content').slideUp(); // Show the clicked accordion if it wasn't active if (!isActive) { $(this).addClass('active'); $(this).find('.accordin_content').slideDown(); } }); function readMoreDirective() { try { if ($(window).width() < 767) { //Toggle content when click on read more link // Show more text option window.lastWidth = $(window).width() var showChar = 230; // How many characters are shown by default var ellipsestext = "..."; var moretext = "Read more"; var lesstext = "Read less"; //Cut content based on showChar length if ($(".toggle-text").length) { $(".toggle-text").each(function() { if (!window.content) { window.content = $(this).html(); } let content = window.content; if (content.length > showChar && !content.includes('')) { var contentExcert = content.substr(0, showChar); var contentRest = content.substr(showChar, content.length - showChar); var html = contentExcert + ' ' + ellipsestext + '' + contentRest + '' + moretext + ''; $(this).html(html); } else { $(this).html(content); } }); } //Toggle content when click on read more link $(".toggle-text-link").click(function() { if ($(this).hasClass("less")) { $(this).removeClass("less"); $(this).html(moretext); } else { $(this).addClass("less"); $(this).html(lesstext); } $(this).parent().prev().toggle(); $(this).prev().toggle(); return false; }); } else { window.lastWidth = $(window).width(); if ($(".toggle-text").length) { $(".toggle-text").each(function() { if (!window.content) { window.content = $(this).html(); } let content = window.content; $(this).html(content); }) } } } catch (e) { // console.warn(e); } } readMoreDirective() $(window).resize(function() { if ($(window).width() != window.lastWidth) { readMoreDirective() initSlick() initializeSlick() initMobileView() initDropdowns() } }); // Hover Mega menu if ($(window).width() > 1201) { // $(document).ready(function () { $('.mega_menu_btn, .header_mega_Menu').mouseover(function() { $('.header_mega_Menu').addClass("is-open"); $('.header_mega_Menu').removeClass("is-closed"); }); $(".header_mega_Menu, #menu-header-menu li:not('.mega_menu_btn')").mouseout(function() { $('.header_mega_Menu').removeClass("is-open"); }); // }); } // Mobile Mega Menu for mobile if ($(window).width() < 1200) { // $(document).ready(function () { $('body').on('click', '.mega_menu_btn', function(event) { event.preventDefault(); $("#mega-menu").toggleClass('is-open'); $(".navbar-collapse").addClass('menu-blured'); }); // }); // back button hide menu $(document).on('click', '.reverse_menu', function(event) { $("#mega-menu").removeClass('is-open'); $(".navbar-collapse").removeClass('menu-blured'); }); } // $(document).ready(function () { // how to work section var lis = $(".work_part > .work_place"); var currentHighlight = 0; var intervalSlide; function startSlideInterval() { intervalSlide = setInterval(function() { currentHighlight = (currentHighlight + 1) % lis.length; lis.removeClass('active').eq(currentHighlight).addClass('active'); }, 3000); } function pauseSlideInterval() { clearInterval(intervalSlide); } $('.work_part > .work_place').on("mouseenter", function(e) { pauseSlideInterval(); lis.removeClass("active"); $(this).addClass("active"); currentHighlight = lis.index(this); // Store the index of the hovered element }); $('.work_part > .work_place').on("mouseleave", function(e) { startSlideInterval(); }); // Add "active" class to the first element lis.eq(0).addClass("active"); startSlideInterval(); // Start the initial slideshow interval // }); // reCaptcha Code removed from here // $(document).ready(function() { var targetElement = $('#dashboard_form'); var recaptchaRendered = false; if (targetElement.length) { $(window).on('scroll', function() { var scrollPosition = $(window).scrollTop(); var elementOffset = targetElement.offset().top; var windowHeight = $(window).height(); if (scrollPosition + windowHeight > elementOffset && !recaptchaRendered) { console.log('Element is in view!'); renderRecaptcha(); recaptchaRendered = true; } }); } else { console.log('Target element #dashboard_form not found.'); } // }); // Reset reCAPTCHA widget function resetRecaptcha2() { if (recaptcha_id) { grecaptcha.reset(recaptcha_id); } } initSlick(); // if ($('#owl-banner').length && $('.owl-navbar').length) { // initializeSlick(); // } loadSlickLibrary(); }); // moved code outside function isNumberKeyPopup(evt) { var input = evt.target; var phoneNumber = input.value.trim(); if (phoneNumber.startsWith('0')) { $("#phone_error").html("Phone number cannot start with 0."); // Clear the input input.value = ''; // Set focus back to the input input.focus(); return false; } var charCode = (evt.which) ? evt.which : evt.keyCode; if (charCode > 31 && (charCode < 48 || charCode > 57)) { $("#phone_error").html("Only digit are allowed"); return false; } else { $("#phone_error").html(""); return true; } } function validatePhoneNumber(evt) { var input = evt.target; var phoneNumber = input.value.trim(); if (phoneNumber.startsWith('0')) { $("#phone_error").html("Phone number cannot start with 0."); // Clear the input // input.value = ''; // Set focus back to the input input.focus(); return false; } else { $("#phone_error").html(""); return true; } } function isNumberKeyInner(evt) { var input = evt.target; var phoneNumber = input.value.trim(); if (phoneNumber.startsWith('0')) { $("#phone_1_error").html("Phone number cannot start with 0."); // Clear the input input.value = ''; // Set focus back to the input input.focus(); return false; } var charCode = (evt.which) ? evt.which : evt.keyCode; if (charCode > 31 && (charCode < 48 || charCode > 57)) { $("#phone_1_error").html("Only digit are allowed"); return false; } else { $("#phone_1_error").html(""); return true; } } function validatePhoneNum(evt) { var input = evt.target; var phoneNumber = input.value.trim(); if (phoneNumber.startsWith('0')) { $("#phone_1_error").html("Phone number cannot start with 0."); // input.value = ''; input.focus(); return false; } else { $("#phone_1_error").html(""); return true; } } function isNumberKeyContact(evt) { var input = evt.target; var phoneNumber = input.value.trim(); if (phoneNumber.startsWith('0')) { $("#phone_2_error").html("Phone number cannot start with 0."); // Clear the input input.value = ''; // Set focus back to the input input.focus(); return false; } var charCode = (evt.which) ? evt.which : evt.keyCode; if (charCode > 31 && (charCode < 48 || charCode > 57)) { $("#phone_2_error").html("Only digit are allowed"); return false; } else { $("#phone_2_error").html(""); return true; } } function validatePhone(evt) { var input = evt.target; var phoneNumber = input.value.trim(); if (phoneNumber.startsWith('0')) { $("#phone_2_error").html("Phone number cannot start with 0."); // input.value = ''; input.focus(); return false; } else { $("#phone_2_error").html(""); return true; } } // reCaptcha code var g_recaptcha; var recaptcha_id; // Ensure grecaptcha is defined if (typeof grecaptcha === 'undefined') { grecaptcha = {}; } // Initialize grecaptcha.ready function grecaptcha.ready = function(cb) { if (typeof grecaptcha === 'undefined') { const c = '___grecaptcha_cfg'; window[c] = window[c] || {}; (window[c]['fns'] = window[c]['fns'] || []).push(cb); } else { cb(); } }; // Load and render reCAPTCHA widgets var onloadCallback = function() { if ($("#g_recaptcha").length && !g_recaptcha) { g_recaptcha = grecaptcha.render("g_recaptcha", { sitekey: "6LdusoUpAAAAAB1ZUr5HFzNoP20KTyHkfQcji9H_" }); } // if ($("#recaptcha_id").length && !recaptcha_id) { // recaptcha_id = grecaptcha.render("recaptcha_id", { // sitekey: "6LdusoUpAAAAAB1ZUr5HFzNoP20KTyHkfQcji9H_" // }); // } console.log("reCAPTCHA has loaded!"); grecaptcha.reset(); }; // Attach event handler to the button function renderRecaptcha() { if ($("#recaptcha_id").length && !recaptcha_id) { recaptcha_id = grecaptcha.render("recaptcha_id", { sitekey: "6LdusoUpAAAAAB1ZUr5HFzNoP20KTyHkfQcji9H_" }); } console.log("reCAPTCHA has loaded on dashboard!"); grecaptcha.reset(); } -->