2017 © Pedro Peláez
 

library php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

image

oguz463/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  • Wednesday, July 4, 2018
  • by oguz463
  • Repository
  • 0 Watchers
  • 0 Stars
  • 178 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 17 Forks
  • 0 Open issues
  • 13 Versions
  • 0 % Grown

The README.md

php-gedcom

Requirements

  • php-gedcom 1.0+ requires PHP 5.3 (or later).

Installation

There are two ways of installing php-gedcom., (*1)

Composer

To install php-gedcom in your project using composer, simply add the following require line to your project's composer.json file:, (*2)

{
    "require": {
        "oguz463/php-gedcom": "1.0.*"
    }
}

Download and __autoload

If you are not using composer, you can download an archive of the source from GitHub and extract it into your project. You'll need to setup an autoloader for the files, unless you go through the painstaking process if requiring all the needed files one-by-one. Something like the following should suffice:, (*3)

spl_autoload_register(function ($class) {
    $pathToPhpGedcom = __DIR__ . '/library/'; // TODO FIXME

    if (!substr(ltrim($class, '\\'), 0, 7) == 'PhpGedcom\\') {
        return;
    }

    $class = str_replace('\\', DIRECTORY_SEPARATOR, $class) . '.php';
    if (file_exists($pathToPhpGedcom . $class)) {
        require_once($pathToPhpGedcom . $class);
    }
});

Usage

To parse a GEDCOM file and load it into a collection of PHP Objects, simply instantiate a new Parser object and pass it the file name to parse. The resulting Gedcom object will contain all the information stored within the supplied GEDCOM file:, (*4)

$parser = new \PhpGedcom\Parser();
$gedcom = $parser->parse('tmp\gedcom.ged');

foreach ($gedcom->getIndi() as $individual) {
    echo $individual->getId() . ': ' . current($individual->getName())->getSurn() .
        ', ' . current($indi->$individual())->getGivn();
}

The Versions

04/07 2018

dev-master

9999999-dev http://github.com/oguz463/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom

04/07 2018

1.0.5

1.0.5.0 http://github.com/oguz463/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom

04/07 2017

1.0.4

1.0.4.0 http://github.com/skypal/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom

22/04 2017

1.0.3

1.0.3.0 http://github.com/skypal/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom

23/03 2017

1.0.2

1.0.2.0 http://github.com/geneanet/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom

08/08 2016

1.0.1

1.0.1.0 http://github.com/geneanet/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom

06/03 2016

dev-2.0-dev

dev-2.0-dev http://github.com/mrkrstphr/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.6+

  Sources   Download

MIT

The Requires

  • php >=5.6

 

The Development Requires

parser gedcom

11/01 2015

dev-streaming-parser

dev-streaming-parser http://github.com/mrkrstphr/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

 

The Development Requires

parser gedcom

08/09 2013

dev-custom-tags

dev-custom-tags http://github.com/mrkrstphr/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

 

The Development Requires

parser gedcom

26/08 2013

dev-parser-2.0

dev-parser-2.0 http://github.com/mrkrstphr/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

 

The Development Requires

parser gedcom

26/08 2013

dev-2.0-devel-old

dev-2.0-devel-old http://github.com/mrkrstphr/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

 

The Development Requires

parser gedcom

18/06 2013

dev-custom-field-wip

dev-custom-field-wip http://github.com/mrkrstphr/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom

29/01 2013

1.0.0

1.0.0.0 http://github.com/mrkrstphr/php-gedcom

A GEDCOM file parser (read + write) for PHP 5.3+

  Sources   Download

GPL-3.0

The Requires

  • php >=5.3

 

The Development Requires

parser gedcom