FREE Lead Management Software

Manage your leads using a user friendly Lead Management System.

Get Started FREE
Free Lead Management Software

Outstanding features at no cost

Affordable, cheap lead management software

Easy-to-use, even with complex workflows

Manage complex workflow with lead management software

Easy implementation with no coding required

Simple Lead Management Software
lead analytics

Surface critical insights to inform marketing decisions

Capture and analyze every call, chat and email with prospects and customers.

Gain complete visibility to sales pipeline and track lead momentum for better lead reviews and forecasting accuracy. Keep a pulse on the competitive landscape.

Stop juggling your lead tracking across multiple tools

Stop wasting time combining data from disconnected tools and databases. Access contact details and follow up with leads all in the same place.

Make sales calls, send emails, assign tasks, leave detailed notes, and more without ever leaving Oryx Cloud. Automatically assign new leads to the right sales reps, create follow-up tasks, and add new deals to your CRM.

lead details of oryxcloud lead management software
call transcription

Every conversation produces a goldmine of insights

Deliver tailored communications to targeted market segments uncovered through keywords surfaced from conversations.

Every conversation produces a goldmine of insights that can inform decision-making and enable go-to-market success..

Collaborate, Nurture leads, and Grow your CRM

All-in-one lead capturing, management and intelligence makes it easy to integrate with your CRM and other apps to build targeted lists, automate your email campaigns, and expand your database.

Import existing lead details, build forms to convert visitors into leads and grow your database, and create unlimited custom fields to collect critical lead details. Then segment contact lists based on any data you’ve collected – lead details, campaign source, lead stage and more.

free lead management software dashboard
Bring Action To Your Clients

Learn How to Grow and Scale your Business in Days

contact and lead management

Contact & Lead Management

Each lead is an opportunity - how well you manage them determines how many of those opportunities turn into actual deals. With our powerful lead management system, you'll never lose track of who's who again. You'll get to know your leads like their best friend!

sales pipeline management software

Pipeline Management

At the end of the day, what matters most is whether or not leads get closed. With our pipeline management system, you can see where leads are in the process at any time - so you get deals done faster than ever before by adding leads to your CRM with a single click.

lead tracking and call transcription

Lead Tracking

Lead tracking software attributes (or matches) incoming phone calls to your marketing channels and tactics. This helps you measure the success of advertising campaigns while fine-tuning marketing strategies and spend.

conversation intelligence and analytics

Conversation Intelligence & Analytics

Boost sales productivity with deep, personalized customer insights. Financial Advisors that develop customer insights can increase sales productivity as much as 40%.

call and voicemail transcription

Call and Voicemail Transcription

Keep a written record of your calls. Special patterns like phone numbers and digits are appropriately formatted. Simply skim the transcription to gather the key details in a few seconds.

crm integration with redtail, salesforce

Easy CRM integration

Attach lead details and call metadata such as recordings, messages, duration, time of call, and more to your software or an off-the-shelf CRM like Salesforce & Redtail.

free form building and form tracking

Form Builder and Tracking

Create your form in minutes using our simple form builder. No coding skills required! Link your Wordpress website with our software that will automatically import the contact details into your CRM in less than 5 minutes. We'll make sure you have everything you need to generate leads from your site.

Bring Action To Your Clients

Transform your client experience

Create the exact solution you need to engage customers at every step of their journey. Oryx Cloud is a single platform with built-in intelligence, and includes all the tools required to manage your leads.

Get Started FREE
free and customized lead management software
lead tracking, lead analytics, lead insights
Bring Action To Your Clients

Business Indices, Lead Tracking Through the Latest Analytics Tools

Quickly identify leads that convert the most quickly and visualize the conversion rate. And get a view into top leads by source and medium.  

8.93%

Increase Monthly

1.07%

Increase Yearly

Bring Action To Your Clients

Create Tasks to your team to manage your workflow

Add, Prioritize & Organize your Team's Tasks! Be more efficient and successful! Start with a simple To-Do-List, add more Details as you go.

Create Tasks

Assign Tasks to Team Members

Manage Status of Tasks

free task manager and workflow manager

Customer Testimonials


Customer Testimonials 1
Customer Testimonials 2
Customer Testimonials 3
Customer Testimonials 4
Customer Testimonials 5
Customer Testimonials 6
Customer Testimonials 7
Customer Testimonials 8
Customer Testimonials 9
Customer Testimonials 10
Customer Testimonials 11

Lead management is the strategy that sales teams use to understand which stages of the pipeline their deals are in. This tracking helps sales teams know whether a lead or prospect is on a path to closing. Many companies choose to use software that streamlines this process and uses automation to encourage leads through the sales process with workflows and targeted marketing.

Oryx Cloud lead management software does exactly that. Instead of using manual tracking, let your sales team leverage the power of a fully automated tracking system. Instead of manually triggering flows or reaching out manually, they’ll be able to use Oryx Cloud lead management smart functionality to trigger interaction at exactly the right time.

Popular features of Oryx Cloud lead management include:
  • Engage with your leads automatically right from within your CRM contact record
  • Automatically update the lead record as soon as a call or email takes place
  • Record all of your customer calls from right within your browser and log them directly to the contact record
  • Make use of templates and automation to make customer follow-up easy
  • Built-in team-wide analytics to understand performance at a macro and micro level

Oryx Cloud’s lead management is part of Sales Hub, and you can get started with it for free. If you’re looking for more advanced features to help automate and scale your sales operations, Oryx Cloud also offers premium features with Starter, Professional, and Enterprise editions of Sales Hub.

Depending on whether you’re already using a lead management system, implementation time may be shorter or longer. If you need to undergo data migration or have a complex or large amount of data to move over, your implementation time may increase. On the other hand, most teams with a short sales cycle also have a very rapid implementation period for lead management software.

For companies that have never done any lead management, the implementation time is instant—the only thing you need to set up before getting started is access for your team and information about their specific roles.

Lead Management in One Unified Tool

Put Oryx Cloud behind your omni-channel marketing strategy to grow inbound conversions, and accelerate your client’s pipeline.

Get Started FREE
free lead management software
// LeadCenter.ai Quiz Application JavaScript class QuizApp { constructor() { this.currentStep = 0; this.totalSteps = 0; this.answers = {}; this.correctAnswerTriggered = false; this.currentQuestionAnsweredCorrectly = false; this.questions = [ // Personal Details Questions { id: 1, question: "Let's start with some basic information about you and your company", type: "personal_details", fields: [ { name: "name", label: "Name", type: "text", required: true, placeholder: "Enter your full name" }, { name: "email", label: "Email Address", type: "email", required: true, placeholder: "Enter your email address" }, { name: "phone", label: "Phone Number", type: "tel", required: true, placeholder: "Enter your phone number" }, { name: "company", label: "Company Name", type: "text", required: true, placeholder: "Enter your company name" }, { name: "employees", label: "Number of Employees", type: "select", required: true, options: [ "1-5", "6-10", "11-20", "20-50", "More than 50 employees" ] } ] }, // Business Questions { id: 2, question: "Which of the following AE Advisors use LeadCenter.AI?", options: [ "Oak Harvest Financial Group", "Howard Bailey", "West Advisory Group", "CA Educators", "Legato Financials", "Slagle Financials", "Freedom Financials", "Comprehensive Advisors", "Jehm Wealth", "Wealth Planning Network", ], type: "multiple" }, { id: 3, question: "Which challenges does LeadCenter.AI solve for financial advisors?", options: [ "Reducing manual data entry", "Breaking silos between marketing, sales, and operations", "Automating tasks to save valuable time", "Engaging more leads, faster", "Boosting lead-to-appointment conversions", "Driving higher revenue", "Simplifying reports and insights", ], type: "multiple" }, { id: 4, question: "Which of the following functions does LeadCenter.AI automate for financial advisors?", options: [ "Capturing leads from all sources (forms, phone calls, seminar registrations)", "Pushing leads to Redtail, Wealthbox, and Salesforce", "Verifying lead phone numbers and emails", "Transcribing calls and attaching them to contact records", "Creating landing pages and seminar forms on the advisor's website", "Sending client review reminders so clients can book their own appointments", "Producing advisor-specific reports (production reports, 1st appointment conversion, ROI, customer acquisition cost, etc.)", "Capturing notes & tasks from Zoom calls under the contact record", "Lead engagement in the sales funnel by triggering emails & texts based on lead criteria" ], type: "multiple" }, { id: 5, question: "How much can an RIA with 5 employees save, boost revenue, and cut software licensing costs by using LeadCenter.AI?", options: [ "Save $10K annually, does not boost revenue, and not cut in software costs", "Save $100K annually, boost revenue by 1x, and cut software costs by $5K", "Save $223K annually by reclaiming up to 434 workdays, boost revenue by up to 3x, and cut software licensing costs by up to $22K" ], type: "single" } ]; // Banner messages for each question this.bannerMessages = { 1: { success: "That's the correct answer! Great job!", wrong: "That is a wrong answer, please try again" }, 2: { success: "Correct! Well done! Today, more than 1,000 advisors rely on LeadCenter.AI. The platform achieved 950% year-over-year growth last year—clear proof of the value it delivers to advisors", wrong: "That is a wrong answer, please try again" }, 3: { success: "That’s correct! LeadCenter.AI was designed in collaboration with financial advisors, built around their feedback to directly address these challenges", wrong: "That is a wrong answer, please try again" }, 4: { success: "That’s correct! LeadCenter.AI streamlines over 400 processes, empowering financial advisors to save time and focus on their clients.", wrong: "That is a wrong answer, please try again" }, 5: { success: "That’s correct! With LeadCenter.AI, advisors eliminate manual work, freeing up valuable time to focus on driving revenue and serving their clients.", wrong: "That is a wrong answer, please try again" } }; this.init(); } init() { this.totalSteps = this.questions.length; this.renderQuestions(); this.updateProgress(); } renderQuestions() { const container = document.querySelector('.question-container'); container.innerHTML = ''; this.questions.forEach((question, index) => { const questionElement = this.createQuestionElement(question, index); container.appendChild(questionElement); }); } createQuestionElement(question, index) { const questionDiv = document.createElement('div'); questionDiv.className = `question-step ${index === 0 ? 'active' : ''}`; questionDiv.id = `question-${question.id}`; questionDiv.style.display = index === 0 ? 'block' : 'none'; const questionCard = document.createElement('div'); questionCard.className = 'question-card'; const questionTitle = document.createElement('h3'); questionTitle.className = 'question-title'; questionTitle.textContent = question.question; questionCard.appendChild(questionTitle); if (question.type === 'personal_details') { // Create form for personal details const formContainer = document.createElement('div'); formContainer.className = 'personal-details-form'; question.fields.forEach(field => { const fieldGroup = document.createElement('div'); fieldGroup.className = 'form-group mb-3'; const label = document.createElement('label'); label.className = 'form-label'; label.textContent = field.label; if (field.required) { label.innerHTML += ' *'; } let input; if (field.type === 'select') { input = document.createElement('select'); input.className = 'form-control'; input.name = `question-${question.id}-${field.name}`; input.id = `q${question.id}-${field.name}`; input.required = field.required; // Add default option const defaultOption = document.createElement('option'); defaultOption.value = ''; defaultOption.textContent = `Select ${field.label.toLowerCase()}`; input.appendChild(defaultOption); // Add options field.options.forEach(option => { const optionElement = document.createElement('option'); optionElement.value = option; optionElement.textContent = option; input.appendChild(optionElement); }); } else { input = document.createElement('input'); input.type = field.type; input.className = 'form-control'; input.name = `question-${question.id}-${field.name}`; input.id = `q${question.id}-${field.name}`; input.placeholder = field.placeholder; input.required = field.required; } fieldGroup.appendChild(label); fieldGroup.appendChild(input); // Add email validation for email field (after input is added to fieldGroup) if (field.type === 'email') { this.addEmailValidation(input, fieldGroup); } // Add phone formatting for phone field if (field.type === 'tel') { this.addPhoneFormatting(input); } // Add event listener to update Next button state for personal details if (question.type === 'personal_details') { input.addEventListener('input', () => { this.updateNavigationButtons(); }); input.addEventListener('change', () => { this.updateNavigationButtons(); }); } formContainer.appendChild(fieldGroup); }); questionCard.appendChild(questionTitle); questionCard.appendChild(formContainer); } else { // Create options for regular questions const optionsList = document.createElement('ul'); optionsList.className = 'question-options'; question.options.forEach((option, optionIndex) => { const optionItem = document.createElement('li'); optionItem.className = 'question-option'; const input = document.createElement('input'); input.type = question.type === 'multiple' ? 'checkbox' : 'radio'; input.className = 'option-input'; input.name = `question-${question.id}`; input.value = option; input.id = `q${question.id}-option${optionIndex}`; // Add event listener for answer detection (correct or wrong) input.addEventListener('change', (e) => { if (question.id === 2) { // Special handling for question 2 - multiple choice, all options must be selected this.checkQuestion2Completion(); } else if (question.id === 3) { // Special handling for question 3 - multiple choice, all options must be selected this.checkQuestion3Completion(); } else if (question.id === 4) { // Special handling for question 4 - multiple choice, all options must be selected this.checkQuestion4Completion(); } else { // Regular single choice questions if (e.target.checked) { // Check if this is a correct answer if (question.id === 5 && option === 'Save $223K annually by reclaiming up to 434 workdays, boost revenue by up to 3x, and cut software licensing costs by up to $22K') { // Correct answer console.log('Correct answer selected!', e.target.checked); this.currentQuestionAnsweredCorrectly = true; if (!this.correctAnswerTriggered) { this.correctAnswerTriggered = true; this.hideWrongAnswerBanner(); this.showSuccessBanner(); this.playFireworks(); } // Don't update navigation buttons - let popup handle progression } else { // Wrong answer console.log('Wrong answer selected!', option); this.currentQuestionAnsweredCorrectly = false; this.hideSuccessBanner(); this.showWrongAnswerBanner(); this.updateNavigationButtons(); } } } }); const label = document.createElement('label'); label.className = 'option-label'; label.htmlFor = `q${question.id}-option${optionIndex}`; label.textContent = option; // Add click listener to label for answer detection label.addEventListener('click', () => { setTimeout(() => { if (question.id === 2) { // Special handling for question 2 - multiple choice, all options must be selected this.checkQuestion2Completion(); } else if (question.id === 3) { // Special handling for question 3 - multiple choice, all options must be selected this.checkQuestion3Completion(); } else if (question.id === 4) { // Special handling for question 4 - multiple choice, all options must be selected this.checkQuestion4Completion(); } else { // Regular single choice questions if (input.checked) { // Check if this is a correct answer if (question.id === 5 && option === 'Save $223K annually by reclaiming up to 434 workdays, boost revenue by up to 3x, and cut software licensing costs by up to $22K') { // Correct answer console.log('Label clicked for correct answer'); this.currentQuestionAnsweredCorrectly = true; if (!this.correctAnswerTriggered) { console.log('Input is checked, triggering effects'); this.correctAnswerTriggered = true; this.hideWrongAnswerBanner(); this.showSuccessBanner(); this.playFireworks(); } // Don't update navigation buttons - let popup handle progression } else { // Wrong answer console.log('Label clicked for wrong answer'); this.currentQuestionAnsweredCorrectly = false; this.hideSuccessBanner(); this.showWrongAnswerBanner(); this.updateNavigationButtons(); } } } }, 100); }); optionItem.appendChild(input); optionItem.appendChild(label); optionsList.appendChild(optionItem); }); questionCard.appendChild(optionsList); // Add hint for specific questions (after options) // Hint removed as requested } questionDiv.appendChild(questionCard); return questionDiv; } updateProgress() { const progressBar = document.getElementById('progress-bar'); const progressText = document.getElementById('progress-text'); const percentage = ((this.currentStep + 1) / this.totalSteps) * 100; progressBar.style.width = `${percentage}%`; progressText.textContent = `Question ${this.currentStep + 1} of ${this.totalSteps}`; } showQuestion(step) { // Hide all questions document.querySelectorAll('.question-step').forEach(question => { question.style.display = 'none'; question.classList.remove('active'); }); // Show current question const currentQuestion = document.getElementById(`question-${this.questions[step].id}`); if (currentQuestion) { currentQuestion.style.display = 'block'; currentQuestion.classList.add('active'); } // Reset flags for new question this.correctAnswerTriggered = false; this.currentQuestionAnsweredCorrectly = false; // Hide any existing banners this.hideSuccessBanner(); this.hideWrongAnswerBanner(); // Update navigation buttons this.updateNavigationButtons(); // Scroll to top of the page window.scrollTo({ top: 0, behavior: 'smooth' }); } updateNavigationButtons() { const prevBtn = document.getElementById('prev-btn'); const nextBtn = document.getElementById('next-btn'); // Show/hide previous button if (this.currentStep === 0) { prevBtn.style.display = 'none'; } else { prevBtn.style.display = 'block'; } // Update next button text if (this.currentStep === this.totalSteps - 1) { nextBtn.innerHTML = 'Submit Quiz'; } else { nextBtn.innerHTML = 'Next'; } // Disable Next button if current question hasn't been answered correctly const currentQuestion = this.questions[this.currentStep]; if (currentQuestion && currentQuestion.type === 'personal_details') { // For personal details, check if all required fields are filled const allFieldsFilled = this.validateCurrentQuestion(); if (allFieldsFilled) { nextBtn.disabled = false; nextBtn.classList.remove('btn-disabled'); } else { nextBtn.disabled = true; nextBtn.classList.add('btn-disabled'); } } else if (currentQuestion && (currentQuestion.id === 2 || currentQuestion.id === 3 || currentQuestion.id === 4)) { // For questions 2, 3, and 4, enable when all options are selected if (this.currentQuestionAnsweredCorrectly) { nextBtn.disabled = false; nextBtn.classList.remove('btn-disabled'); } else { nextBtn.disabled = true; nextBtn.classList.add('btn-disabled'); } } else { // For other quiz questions, disable until correct answer is selected if (this.currentQuestionAnsweredCorrectly) { nextBtn.disabled = false; nextBtn.classList.remove('btn-disabled'); } else { nextBtn.disabled = true; nextBtn.classList.add('btn-disabled'); } } } saveAnswer() { const currentQuestion = this.questions[this.currentStep]; const questionId = currentQuestion.id; if (currentQuestion.type === 'personal_details') { this.answers[questionId] = {}; currentQuestion.fields.forEach(field => { const input = document.querySelector(`input[name="question-${questionId}-${field.name}"], select[name="question-${questionId}-${field.name}"]`); this.answers[questionId][field.name] = input ? input.value : ''; }); } else if (currentQuestion.type === 'multiple') { const checkboxes = document.querySelectorAll(`input[name="question-${questionId}"]:checked`); this.answers[questionId] = Array.from(checkboxes).map(cb => cb.value); } else { const radio = document.querySelector(`input[name="question-${questionId}"]:checked`); this.answers[questionId] = radio ? radio.value : null; } } loadAnswer() { const currentQuestion = this.questions[this.currentStep]; const questionId = currentQuestion.id; const savedAnswer = this.answers[questionId]; if (savedAnswer) { if (currentQuestion.type === 'personal_details') { currentQuestion.fields.forEach(field => { const input = document.querySelector(`input[name="question-${questionId}-${field.name}"], select[name="question-${questionId}-${field.name}"]`); if (input && savedAnswer[field.name]) { input.value = savedAnswer[field.name]; } }); } else if (currentQuestion.type === 'multiple') { savedAnswer.forEach(answer => { const checkbox = document.querySelector(`input[name="question-${questionId}"][value="${answer}"]`); if (checkbox) checkbox.checked = true; }); } else { const radio = document.querySelector(`input[name="question-${questionId}"][value="${savedAnswer}"]`); if (radio) radio.checked = true; } } } validateCurrentQuestion() { const currentQuestion = this.questions[this.currentStep]; const questionId = currentQuestion.id; if (currentQuestion.type === 'personal_details') { // Check all required fields are filled for (let field of currentQuestion.fields) { if (field.required) { const input = document.querySelector(`input[name="question-${questionId}-${field.name}"], select[name="question-${questionId}-${field.name}"]`); if (!input || !input.value.trim()) { return false; } // Validate email format if it's an email field if (field.type === 'email') { const emailRegex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/; if (!emailRegex.test(input.value.trim())) { return false; } } } } return true; } else if (currentQuestion.type === 'multiple') { if (questionId === 2 || questionId === 3 || questionId === 4) { // For questions 2, 3, and 4, only allow progression if all options are selected const allInputs = document.querySelectorAll(`input[name="question-${questionId}"]`); const checkedInputs = document.querySelectorAll(`input[name="question-${questionId}"]:checked`); return checkedInputs.length === allInputs.length; } else { // For other multiple choice questions, just check if at least one is selected const checkboxes = document.querySelectorAll(`input[name="question-${questionId}"]:checked`); return checkboxes.length > 0; } } else { const radio = document.querySelector(`input[name="question-${questionId}"]:checked`); return radio !== null; } } nextQuestion() { if (!this.validateCurrentQuestion()) { const currentQuestion = this.questions[this.currentStep]; // Don't show validation messages for questions 2, 3, and 4 if (currentQuestion.id === 2 || currentQuestion.id === 3 || currentQuestion.id === 4) { return; } let message = 'Please complete all required fields before proceeding.'; if (currentQuestion.type === 'personal_details') { message = 'Please fill in all required fields and check your email format.'; } else if (currentQuestion.type === 'multiple') { message = 'Please select at least one option before proceeding.'; } else { message = 'Please select an answer before proceeding.'; } this.showValidationMessage(message); return; } this.saveAnswer(); if (this.currentStep < this.totalSteps - 1) { this.currentStep++; this.showQuestion(this.currentStep); this.loadAnswer(); this.updateProgress(); } else { this.submitQuiz(); } } previousQuestion() { if (this.currentStep > 0) { this.saveAnswer(); this.currentStep--; this.showQuestion(this.currentStep); this.loadAnswer(); this.updateProgress(); } } showValidationMessage(message) { // Remove existing validation message const existingMessage = document.querySelector('.validation-message'); if (existingMessage) { existingMessage.remove(); } // Create new validation message const validationDiv = document.createElement('div'); validationDiv.className = 'alert alert-warning validation-message'; validationDiv.innerHTML = `${message}`; // Insert after current question const currentQuestion = document.querySelector('.question-step.active'); currentQuestion.appendChild(validationDiv); // Auto-remove after 3 seconds setTimeout(() => { if (validationDiv.parentNode) { validationDiv.remove(); } }, 3000); } submitQuiz() { this.saveAnswer(); // Show loading state const nextBtn = document.getElementById('next-btn'); const originalText = nextBtn.innerHTML; nextBtn.innerHTML = ' Submitting...'; nextBtn.disabled = true; // Simulate API call setTimeout(() => { this.showThankYouStep(); }, 2000); } showThankYouStep() { // Hide quiz steps document.getElementById('quiz-steps').style.display = 'none'; // Show thank you step document.getElementById('step-thankyou').style.display = 'block'; document.getElementById('step-thankyou').classList.add('active'); // Log answers for debugging console.log('Quiz Answers:', this.answers); } restartQuiz() { // Reset state this.currentStep = 0; this.answers = {}; this.correctAnswerTriggered = false; this.currentQuestionAnsweredCorrectly = false; // Hide thank you step document.getElementById('step-thankyou').style.display = 'none'; document.getElementById('step-thankyou').classList.remove('active'); // Show intro step document.getElementById('step-intro').style.display = 'block'; document.getElementById('step-intro').classList.add('active'); // Reset form document.querySelectorAll('.option-input').forEach(input => { input.checked = false; }); // Hide banners this.hideSuccessBanner(); this.hideWrongAnswerBanner(); this.updateProgress(); } showSuccessBanner() { console.log('Showing success popup...'); const popup = document.getElementById('success-popup'); if (popup) { // Get current question and update text dynamically const currentQuestion = this.questions[this.currentStep]; const message = this.bannerMessages[currentQuestion.id]?.success || "That's the correct answer! Great job!"; // Update the popup text const popupText = document.getElementById('success-popup-text'); if (popupText) { popupText.textContent = message; } // Update button text based on question number const nextButton = popup.querySelector('button[onclick="proceedToNextQuestion()"]'); if (nextButton) { if (currentQuestion.id === 5) { nextButton.innerHTML = 'Submit Quiz '; } else { nextButton.innerHTML = 'Next Question '; } } // Show the modal using Bootstrap const modal = new bootstrap.Modal(popup); modal.show(); console.log('Success popup displayed'); } else { console.error('Success popup element not found!'); } } hideSuccessBanner() { const popup = document.getElementById('success-popup'); if (popup) { const modal = bootstrap.Modal.getInstance(popup); if (modal) { modal.hide(); } } } showWrongAnswerBanner() { console.log('Showing wrong answer banner...'); const banner = document.getElementById('wrong-answer-banner'); if (banner) { // Get current question and update text dynamically const currentQuestion = this.questions[this.currentStep]; const message = this.bannerMessages[currentQuestion.id]?.wrong || "That is a wrong answer, please try again"; // Update the banner text const bannerText = banner.querySelector('strong'); if (bannerText) { bannerText.textContent = message; } banner.style.display = 'block'; console.log('Wrong answer banner displayed'); // Auto-hide after 3 seconds setTimeout(() => { this.hideWrongAnswerBanner(); }, 3000); } else { console.error('Wrong answer banner element not found!'); } } hideWrongAnswerBanner() { const banner = document.getElementById('wrong-answer-banner'); if (banner) { banner.style.display = 'none'; } } addEmailValidation(input, fieldGroup) { // Create error message element const errorElement = document.createElement('div'); errorElement.className = 'email-error text-danger small mt-1'; errorElement.style.display = 'none'; errorElement.textContent = 'Please enter a valid email address in the format name@company.com'; // Add error element after the input fieldGroup.appendChild(errorElement); // Email validation function const validateEmail = (email) => { const emailRegex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/; return emailRegex.test(email); }; // Add event listeners input.addEventListener('blur', () => { const email = input.value.trim(); if (email && !validateEmail(email)) { errorElement.style.display = 'block'; input.classList.add('is-invalid'); } else { errorElement.style.display = 'none'; input.classList.remove('is-invalid'); } }); input.addEventListener('input', () => { const email = input.value.trim(); if (email && !validateEmail(email)) { errorElement.style.display = 'block'; input.classList.add('is-invalid'); } else { errorElement.style.display = 'none'; input.classList.remove('is-invalid'); } }); } addPhoneFormatting(input) { // Set placeholder to show the expected format input.placeholder = '(XXX) XXX-XXXX'; // Add input event listener for formatting input.addEventListener('input', (e) => { let value = e.target.value.replace(/\D/g, ''); // Remove all non-digits // Limit to 10 digits if (value.length > 10) { value = value.substring(0, 10); } // Format the phone number let formattedValue = ''; if (value.length > 0) { if (value.length <= 3) { formattedValue = `(${value}`; } else if (value.length <= 6) { formattedValue = `(${value.substring(0, 3)}) ${value.substring(3)}`; } else { formattedValue = `(${value.substring(0, 3)}) ${value.substring(3, 6)}-${value.substring(6)}`; } } e.target.value = formattedValue; }); // Add keydown event listener to prevent non-numeric input input.addEventListener('keydown', (e) => { // Allow: backspace, delete, tab, escape, enter, home, end, left, right, up, down if ([8, 9, 27, 13, 46, 35, 36, 37, 38, 39, 40].indexOf(e.keyCode) !== -1 || // Allow: Ctrl+A, Ctrl+C, Ctrl+V, Ctrl+X (e.keyCode === 65 && e.ctrlKey === true) || (e.keyCode === 67 && e.ctrlKey === true) || (e.keyCode === 86 && e.ctrlKey === true) || (e.keyCode === 88 && e.ctrlKey === true)) { return; } // Ensure that it is a number and stop the keypress if ((e.shiftKey || (e.keyCode < 48 || e.keyCode > 57)) && (e.keyCode < 96 || e.keyCode > 105)) { e.preventDefault(); } }); // Add paste event listener to handle pasted content input.addEventListener('paste', (e) => { e.preventDefault(); const pastedData = e.clipboardData.getData('text'); const numbersOnly = pastedData.replace(/\D/g, ''); if (numbersOnly.length <= 10) { input.value = numbersOnly; input.dispatchEvent(new Event('input')); } }); } checkQuestion2Completion() { // Check if all options for question 2 are selected const question2Inputs = document.querySelectorAll('input[name="question-2"]'); const checkedInputs = document.querySelectorAll('input[name="question-2"]:checked'); console.log(`Question 2: ${checkedInputs.length} of ${question2Inputs.length} options selected`); if (checkedInputs.length === question2Inputs.length) { // All options selected - show success popup this.currentQuestionAnsweredCorrectly = true; if (!this.correctAnswerTriggered) { this.correctAnswerTriggered = true; this.hideWrongAnswerBanner(); this.showSuccessBanner(); this.playFireworks(); } // Don't update navigation buttons - let popup handle progression } else { // Not all options selected - hide success popup but don't show error this.currentQuestionAnsweredCorrectly = false; this.hideSuccessBanner(); this.hideWrongAnswerBanner(); // Don't show error message for question 2 this.updateNavigationButtons(); } } checkQuestion3Completion() { // Check if all options for question 3 are selected const question3Inputs = document.querySelectorAll('input[name="question-3"]'); const checkedInputs = document.querySelectorAll('input[name="question-3"]:checked'); console.log(`Question 3: ${checkedInputs.length} of ${question3Inputs.length} options selected`); if (checkedInputs.length === question3Inputs.length) { // All options selected - show success popup this.currentQuestionAnsweredCorrectly = true; if (!this.correctAnswerTriggered) { this.correctAnswerTriggered = true; this.hideWrongAnswerBanner(); this.showSuccessBanner(); this.playFireworks(); } // Don't update navigation buttons - let popup handle progression } else { // Not all options selected - hide success popup but don't show error this.currentQuestionAnsweredCorrectly = false; this.hideSuccessBanner(); this.hideWrongAnswerBanner(); // Don't show error message for question 3 this.updateNavigationButtons(); } } checkQuestion4Completion() { // Check if all options for question 4 are selected const question4Inputs = document.querySelectorAll('input[name="question-4"]'); const checkedInputs = document.querySelectorAll('input[name="question-4"]:checked'); console.log(`Question 4: ${checkedInputs.length} of ${question4Inputs.length} options selected`); if (checkedInputs.length === question4Inputs.length) { // All options selected - show success popup this.currentQuestionAnsweredCorrectly = true; if (!this.correctAnswerTriggered) { this.correctAnswerTriggered = true; this.hideWrongAnswerBanner(); this.showSuccessBanner(); this.playFireworks(); } // Don't update navigation buttons - let popup handle progression } else { // Not all options selected - hide success popup but don't show error this.currentQuestionAnsweredCorrectly = false; this.hideSuccessBanner(); this.hideWrongAnswerBanner(); // Don't show error message for question 4 this.updateNavigationButtons(); } } playFireworks() { console.log('Playing confetti celebration...'); // Use confetti library for celebration if (typeof confetti !== 'undefined') { try { // Multiple confetti bursts for better effect const duration = 3000; const animationEnd = Date.now() + duration; const defaults = { startVelocity: 30, spread: 360, ticks: 60, zIndex: 1000 }; function randomInRange(min, max) { return Math.random() * (max - min) + min; } const interval = setInterval(function() { const timeLeft = animationEnd - Date.now(); if (timeLeft <= 0) { return clearInterval(interval); } const particleCount = 50 * (timeLeft / duration); // Launch confetti from different positions confetti({ ...defaults, particleCount, origin: { x: randomInRange(0.1, 0.3), y: Math.random() - 0.2 } }); confetti({ ...defaults, particleCount, origin: { x: randomInRange(0.7, 0.9), y: Math.random() - 0.2 } }); }, 250); console.log('Confetti celebration started'); } catch (error) { console.error('Error with confetti:', error); this.showCelebrationFallback(); } } else { console.log('Confetti library not available, using fallback'); this.showCelebrationFallback(); } } showCelebrationFallback() { console.log('Showing celebration fallback...'); // Create a simple celebration overlay const celebration = document.createElement('div'); celebration.id = 'celebration-fallback'; celebration.style.position = 'fixed'; celebration.style.top = '0'; celebration.style.left = '0'; celebration.style.width = '100%'; celebration.style.height = '100%'; celebration.style.background = 'linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57)'; celebration.style.display = 'flex'; celebration.style.alignItems = 'center'; celebration.style.justifyContent = 'center'; celebration.style.zIndex = '9999'; celebration.style.fontSize = '3rem'; celebration.style.fontWeight = 'bold'; celebration.style.color = 'white'; celebration.style.textAlign = 'center'; celebration.style.animation = 'pulse 0.5s ease-in-out infinite alternate'; celebration.innerHTML = '🎉
CORRECT!
🎉'; document.body.appendChild(celebration); // Remove after 3 seconds setTimeout(() => { if (document.body.contains(celebration)) { document.body.removeChild(celebration); } }, 3000); } } // Global functions for button clicks let quizApp; function startQuiz() { // Hide intro step document.getElementById('step-intro').style.display = 'none'; document.getElementById('step-intro').classList.remove('active'); // Show quiz steps document.getElementById('quiz-steps').style.display = 'block'; // Scroll to top of the page window.scrollTo({ top: 0, behavior: 'smooth' }); // Initialize quiz app quizApp = new QuizApp(); } function nextQuestion() { if (quizApp) { quizApp.nextQuestion(); } } function previousQuestion() { if (quizApp) { quizApp.previousQuestion(); } } function restartQuiz() { if (quizApp) { quizApp.restartQuiz(); } } function proceedToNextQuestion() { if (quizApp) { // Hide the success popup quizApp.hideSuccessBanner(); // Proceed to next question quizApp.nextQuestion(); } } // Initialize when page loads document.addEventListener('DOMContentLoaded', function() { // Add smooth scrolling document.querySelectorAll('a[href^="#"]').forEach(anchor => { anchor.addEventListener('click', function (e) { e.preventDefault(); document.querySelector(this.getAttribute('href')).scrollIntoView({ behavior: 'smooth' }); }); }); // Add form validation styles const style = document.createElement('style'); style.textContent = ` .validation-message { margin-top: 1rem; animation: slideDown 0.3s ease; } @keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } } .option-label:focus-within { outline: 2px solid var(--primary-color); outline-offset: 2px; } `; document.head.appendChild(style); // Test function for debugging window.testFireworks = function() { console.log('Testing fireworks and banner...'); if (quizApp) { quizApp.showSuccessBanner(); quizApp.playFireworks(); } else { console.log('Quiz app not initialized yet'); } }; });