Zencart version: 1.3.9h, newly installed.
I installed an addon created by Payfast.co.za, a South African payment gateway.
Customisations: I have created a new template and changed colours and logo.

I have set up my store and created products. I also used the Payfast addon to the payments module to collect payment from customers using the Payfast gateway.

I have been testing the site and everything works as I would expect, all emails are sent, gift certificates are sent and redeemed when new customers register, etc.

Problem: When a proceeding to checkout, the site gets redirected to the Payfast payment gateway and payment is collected. Payfast redirects back to my site after payment has been collected and I get to the Checkout Success page.

However, no order is created. No order number is generated so the order number field on Checkout Success is blank. When I log into the admin panel and view the Orders report, there are no orders. If a gift certificate was used in the purchase, the balance is reset as if it had not been used.

I do receive email confirmations from the Payfast gateway showing that payments have been collected and my Zencart site seems to receive the confirmation from Payfast because it shows the Checkout Success page, but no order is created.

I would be grateful for any advice on how to fix this.

Many thanks
Bruce