resourcebundle.inc 512 B

1234567891011121314151617181920
  1. <?php
  2. // FIXME Improve Endian check when endian const gets added
  3. // Check if platform is Big or Little endian
  4. if (pack('S', 0xABCD) !== pack('v', 0xABCD)) {
  5. $endian = 'be';
  6. } else {
  7. $endian = 'le';
  8. }
  9. define('BUNDLE', __DIR__ . '/_files/resourcebundle_' . $endian);
  10. function debug( $res ) {
  11. if (is_null( $res )) {
  12. $ret = "NULL\n";
  13. }
  14. else {
  15. $ret = print_r( $res, true ). "\n";
  16. }
  17. return $ret . sprintf( "%5d: %s\n", intl_get_error_code(), intl_get_error_message() );
  18. }