After lot of bang bang. I could find a way to do 3 tasks with Square Payment Form in PHP
- Check from Square Customer Director if USER EXISTS based on PHONE number - If yes Get "CUSTOMER ID" and MAKE PAYMENT
- If Customer does not exists in Directory -- CREATE A NEW USER -- GO & GET --> find CUSTOMER ID --> & MAKE PAYMENT
- Get PAYMENT ID & SAVE IT IN MySQL Database
PS : This is very crud way of scripting (hahaha). Had to find a way to get this project done. I found out simple way by using GOTO statement. Hope it will help you of my 3 weeks of in between projects and delivered.
ENV file -- env (without extension -- plain text file)
Genarate Square Idempotency Key CLASS) - square-functions.php
HTML FORM - paynow.php
PROCESS PAYMENT Page --- process-payment.php
No comments:
Post a Comment