Worldpay response error:

     

In my website transaction works from Magento to Worldpay completely fine and payments go through to the merchant account successfully. but the problem occurs after a transaction when returning to the site.


The customer receives an email from Worldpay but the information is not transferred back to Magento. Transaction statuses are displayed as "Payment Pending". Worldpay takes us back to Magento but we receive a message just saying "Error Occurred....." and it will redirected to empty cart.