Skip to content

Instantly share code, notes, and snippets.

@phamquocbuu
Created August 3, 2018 07:34
Show Gist options
  • Select an option

  • Save phamquocbuu/8a4ed15b66e4966db6384606f54c638f to your computer and use it in GitHub Desktop.

Select an option

Save phamquocbuu/8a4ed15b66e4966db6384606f54c638f to your computer and use it in GitHub Desktop.
PHP-CSV - add BOM to fix UTF-8 in Excel
<?php
fputs($fp, $bom =( chr(0xEF) . chr(0xBB) . chr(0xBF) ));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment