Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

changed from whatsapp to call number #19

Merged
merged 1 commit into from
Dec 23, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 4 additions & 7 deletions client/src/pages/NoRIdeAvailable.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,8 @@ const NoRIdeAvailable = () => {
};
const sendMessage = () => {
// let number = whatsappNumber.replace(/[^\w\s]/gi, "").replace(/ /g, "");
let url = `https://web.whatsapp.com/send?phone=${process.env.REACT_APP_NUMBER}`;
url += `&text=${encodeURI(
"Hi Glideride! Please add me to waiting list and Notify me as soon as ride is possible"
)}&app_absent=0`;
window.open(url);
const number = process.env.REACT_APP_NUMBER;
window.location.href = `tel:${number}`;
};
return (
<form onSubmit={addToWaitingList}>
Expand All @@ -32,11 +29,11 @@ const NoRIdeAvailable = () => {
htmlFor="whatsappNumber"
className="block text-gray-600 text-sm"
>
Click Here to add You to our waiting List
Call Us to add you to our waiting list
</label>
</div>
<button className="bg-yellow-500 text-black font-sans px-4 py-2 rounded-md">
Add Me!
Call 7310691665
</button>
</div>
</form>
Expand Down