29
Jan 14

Moneris API (Global Error Receipt)

Recently, I was implementing an e-payment solution for a website using Moneris’s PHP API. The configuration process to enable the use of cURL PHP extension went well according to their documentation.  However, the provided API’s code is a total mess. It generates lots of warnings and lacks of necessary data validation. But, still, it gives you some hints to interact with their web services.  Luckily, I found a clean API which I modified to add support for all the returned status code.  Everything worked fine until the moment I receive an error saying “Global Error Receipt”. Uhu? Moneris’s documentation says “You are not connecting to our servers. This can be caused by a firewall or your internet connection”. It turned out that for some reasons, the API was not able to access the cURL certificate which resulted in such error.


27
May 13

Installing XAMPP on a USB Stick

Sometimes you need to have a portable WAMP development environment. Although many solutions exist (such as WampServer, EasyPHP, etc), I prefer to use XAMPP since it’s loaded with many useful features and packages. Furthermore, XAMPP is provided in a “Portable” lite version which can be found here.

First, select and download an XAMPP Portable Lite zip file and extract it locally on your computer. Then, copy the extracted xampp folder to your USB stick (it might take up to 30 minutes). Once copy is successfully completed and prior to launch XAMPP’s control panel, you need to run the setup_xampp.bat script in order to setup some PHP related environment variables.