🤖 WordPress Lead Bot Builder
Create professional lead generation chatbots for WordPress – No coding required!
📋 How to Use This Builder:
- Choose an industry template or start blank
- Customize your bot title and business info
- Add/edit questions and answer options
- Preview your bot in real-time
- Generate the shortcode for WordPress
- Copy and paste the code into your WordPress site
🛠️ Bot Configuration
🌡️ HVAC
Heating & AC
🔧 Plumbing
Plumbing Services
🦷 Dental
Dental Practice
⚖️ Legal
Law Firm
📝 Custom
Start Fresh
❓ Questions
📱 Live Preview
Your Bot Title
Your Business Name
Welcome! Let’s get started…
L
3 / 3
This response paused because Claude reached its max length for a message. Hit continue to nudge Claude along.
// WordPress Lead Bot Builder JavaScript
var LeadBotBuilder = {
botConfig: {
title: '',
business: '',
color: '#667eea',
phone: '',
questions: [],
clones: []
},
cloneCounter: 0,
industryTemplates: {
hvac: {
title: "AC Problem Solver",
questions: [
{
id: 1,
text: "What type of HVAC service do you need?",
options: ["Emergency Repair", "Routine Service", "New System", "Just Have Questions"]
},
{
id: 2,
text: "What's your emergency?",
options: ["No Cooling/Heating", "Strange Noises", "High Electric Bills", "System Won't Start"]
},
{
id: 3,
text: "When would you like service?",
options: ["Today", "Tomorrow", "This Week", "Next Week"]
}
]
},
plumbing: {
title: "Plumbing Problem Solver",
questions: [
{
id: 1,
text: "What plumbing issue can we help with?",
options: ["Emergency Repair", "Drain Cleaning", "New Installation", "Routine Maintenance"]
},
{
id: 2,
text: "How urgent is this issue?",
options: ["Emergency - Right Now", "Today", "This Week", "Not Urgent"]
}
]
},
pool: {
title: "Pool Service Helper",
questions: [
{
id: 1,
text: "What pool services do you need?",
options: ["Weekly Cleaning", "Equipment Repair", "Pool Remodel", "Chemical Treatment"]
},
{
id: 2,
text: "What's your pool size?",
options: ["Small (under 15k gal)", "Medium (15-25k gal)", "Large (25k+ gal)", "Not sure"]
}
]
},
dental: {
title: "Dental Appointment Helper",
questions: [
{
id: 1,
text: "What brings you to our office?",
options: ["Routine Cleaning", "Tooth Pain", "Cosmetic Work", "Emergency"]
},
{
id: 2,
text: "When would you like to schedule?",
options: ["This Week", "Next Week", "Next Month", "Just Looking"]
}
]
},
legal: {
title: "Legal Help Assistant",
questions: [
{
id: 1,
text: "What type of legal help do you need?",
options: ["Personal Injury", "Family Law", "Business Law", "Real Estate"]
},
{
id: 2,
text: "How urgent is your legal matter?",
options: ["Very Urgent", "Somewhat Urgent", "Not Urgent", "Just Exploring"]
}
]
},
blank: {
title: "Custom Bot",
questions: []
}
},
init: function() {
this.bindEvents();
this.buildQuestionInterface();
this.previewBot();
},
bindEvents: function() {
var self = this;
// Template card clicks
jQuery('.template-card').on('click', function() {
self.selectTemplate(jQuery(this).data('template'));
});
// Form input changes
jQuery('#botTitle, #clientBusiness, #primaryColor, #clientPhone').on('input', function() {
self.previewBot();
});
},
selectTemplate: function(industry) {
// Remove active class from all cards
jQuery('.template-card').removeClass('active');
// Add active class to selected card
jQuery('[data-template="' + industry + '"]').addClass('active');
// Load template
var template = this.industryTemplates[industry];
jQuery('#botTitle').val(template.title);
this.botConfig.questions = JSON.parse(JSON.stringify(template.questions));
this.buildQuestionInterface();
this.previewBot();
},
buildQuestionInterface: function() {
var self = this;
var container = jQuery('#questionBuilder');
container.empty();
this.botConfig.questions.forEach(function(question, index) {
var questionDiv = jQuery('<div class="question-builder"></div>');
questionDiv.html(`
<div class="question-header">
<h4>Question ${index + 1}</h4>
<button class="btn btn-danger" onclick="LeadBotBuilder.removeQuestion(${index})" style="padding: 5px 10px; font-size: 12px;">❌ Remove</button>
</div>
<div class="form-group">
<label>Question Text:</label>
<input type="text" value="${question.text}" onchange="LeadBotBuilder.updateQuestion(${index}, 'text', this.value)">
</div>
<div class="form-group">
<label>Answer Options (one per line):</label>
<textarea rows="4" onchange="LeadBotBuilder.updateQuestionOptions(${index}, this.value)">${question.options.join('\n')}</textarea>
</div>
`);
container.append(questionDiv);
});
},
addQuestion: function() {
var newQuestion = {
id: this.botConfig.questions.length + 1,
text: "Your question here...",
options: ["Option 1", "Option 2", "Option 3"]
};
this.botConfig.questions.push(newQuestion);
this.buildQuestionInterface();
this.previewBot();
},
removeQuestion: function(index) {
this.botConfig.questions.splice(index, 1);
this.buildQuestionInterface();
this.previewBot();
},
updateQuestion: function(index, field, value) {
if (this.botConfig.questions[index]) {
this.botConfig.questions[index][field] = value;
this.previewBot();
}
},
updateQuestionOptions: function(index, value) {
if (this.botConfig.questions[index]) {
this.botConfig.questions[index].options = value.split('\n').filter(function(opt) {
return opt.trim();
});
this.previewBot();
}
},
previewBot: function() {
var title = jQuery('#botTitle').val() || 'Your Bot Title';
var business = jQuery('#clientBusiness').val() || 'Business Name';
var color = jQuery('#primaryColor').val();
jQuery('#previewTitle').text(title);
jQuery('#previewBusiness').text(business);
// Update colors
var header = jQuery('#botHeaderPreview');
header.css('background', 'linear-gradient(45deg, ' + color + ', ' + this.adjustColor(color, -20) + ')');
// Show first question if available
var questionDiv = jQuery('#botQuestionPreview');
if (this.botConfig.questions.length > 0) {
var firstQuestion = this.botConfig.questions[0];
var optionsHtml