Laravel Queue and Job

Official Doc:

Command to build job class:

Command to dispatch job:

Command to execute start queue worker:


  • Every time related scripts are changed, the queue worker must be restarted or the job will always read the script in some cache.

ECPay e-invoice

Response after invoice is created:


Install Apache + PHP + MySQL Manually on Windows Server 2008

  1. Install Visual C++ Redistributable 2012
    VC version is very very very important! VC 2012 = VC11, Apache and PHP must be the same version VC11
  2. Install Apache: (win64)
  3. Edit httpd.conf
  4. Install service:
    httpd -k install -n “Apache 2.4”
  5. Install PHP
    If using laravel which require openssl_encrypt function, you must choose threat safe version:
  6. Edit php.ini
  7. Enable .htaccess in Apache:
    1. Set AllowOverride All for document directory.
    2. Enable rewrite module:
      LoadModule rewrite_module modules/


Advanced where clause – pass variable into annonymous function


PHPexcel: Error loading file “uploaded_order.xls”: Unknown codepage: 10002

Error loading file “uploaded_order.xls”: Unknown codepage: 10002

Reason: This file could made on Mac and cause some identify issue.


Add this line in PHPExcel/Shared/CodePage.php





ECPay Cancel Order (Refund credit card)


ECPay response example with extra payment info



Old utf8 char_set could cause unexpected error like

Here is example string:

To solve this, change char set settings in config file of CodeIgniter: