*ARCHIVED* -- This repository is no longer maintained, and is useful for archive purposes only. PHP support library for the Humanitarian Exchange Language (HXL) data standard.
PHP Shell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
HXL
tests
tools
.gitignore
LICENSE.md
README.md
run-tests.sh

README.md

Humanitarian Exchange Language (HXL) PHP Library

Started by David Megginson, August 2014

Description

PHP5 library for parsing HXL-tagged data. For more information about HXL, see http://docs.hdx.rwlabs.org/hxl

Usage

require_once('HXL/HXL.php');

$input = fopen('MyFile.csv', 'r');
$hxl = new HXLReader($input);

foreach ($hxl as $row) {
  printf("Row %d:\n", $row->rowNumber);
  foreach ($row as $value) {
    printf(" %s=%s\n", $value->header->tag, $value->content);
  }
}

fclose($input);

Requirements

  • PHP5
  • PHPUnit to run unit tests.