Honda219 commited on
Commit
59cd996
·
verified ·
1 Parent(s): 4f512fa

🐳 17/06 - 15:42 - When the date is selected, please put the day of the week between "for" and "date". For example, is booked for Thursday 06/18/2026 at 11:45 am EST. that is how it should read

Browse files
Files changed (1) hide show
  1. index.html +4 -1
index.html CHANGED
@@ -1066,12 +1066,15 @@
1066
  // Format date as MM/DD/YYYY
1067
  const formattedDate = `${(estDate.getMonth() + 1).toString().padStart(2, '0')}/${estDate.getDate().toString().padStart(2, '0')}/${estDate.getFullYear()}`;
1068
 
 
 
 
1069
  // Get client name if provided
1070
  const clientName = document.getElementById('clientName').value.trim();
1071
  const greeting = clientName ? `Hello ${clientName},` : 'Hello,';
1072
 
1073
  // Generate the script
1074
- const script = `${greeting} your appointment with Derrin at UML is booked for ${formattedDate} at ${convertedTime} ${timezoneLabel}. Please reply with C to confirm or R to reschedule. Call or text this number (313) 490-3990 to reschedule.`;
1075
 
1076
  // Display the generated script
1077
  generatedScript.textContent = script;
 
1066
  // Format date as MM/DD/YYYY
1067
  const formattedDate = `${(estDate.getMonth() + 1).toString().padStart(2, '0')}/${estDate.getDate().toString().padStart(2, '0')}/${estDate.getFullYear()}`;
1068
 
1069
+ // Get day of the week
1070
+ const dayOfWeek = estDate.toLocaleDateString('en-US', { weekday: 'long' });
1071
+
1072
  // Get client name if provided
1073
  const clientName = document.getElementById('clientName').value.trim();
1074
  const greeting = clientName ? `Hello ${clientName},` : 'Hello,';
1075
 
1076
  // Generate the script
1077
+ const script = `${greeting} your appointment with Derrin at UML is booked for ${dayOfWeek} ${formattedDate} at ${convertedTime} ${timezoneLabel}. Please reply with C to confirm or R to reschedule. Call or text this number (313) 490-3990 to reschedule.`;
1078
 
1079
  // Display the generated script
1080
  generatedScript.textContent = script;