Ignoring the absolute madness of my classes and names (this is a desperate mess from me trying 10000 different ways to structure this, so it needs refactoring/cleaning/rewriting!)
php code:
<?php
class GedComDom extends DOMDocument {
private $gedcom;
private $linesraw;
private $root;
private $path;
public $xpath;
public function __construct ($path){
parent::__construct();
$this->path = $path;
$this->xpath = new DOMXPath($this);
$this->registerNodeClass('DOMDocument', 'GedComDom');
$this->registerNodeClass('DOMElement', 'GedComDomElement');
$this->root = $this->setRoot('GEDCOM');
$this->individuals = $this->addCollection("INDIVIDUALS");
$this->families = $this->addCollection("FAMILIES");
$this->gedcom = file_get_contents($this->path);
$this->linesraw = explode("\r\n", $this->gedcom);
$currentobj = null;
for &
…[Message Truncated]
View full message.