you may want to go to pear.php.net and search for XML_tree....
they have something that you can use...
you want to read this about [man]references[/man] in php... not exactly pointers... but you can do this...
which is just furthering what Weedpacket suggests
<?php
class Node
{
var $next;
var $last;
var $data;
function Node( $data='' )
{
$this->next = NULL;
$this->last = NULL;
$this->data = $data;
}
}
$root = new Node( 'I AM THE ROOT' );
$root->next = new Node( 'A' );
$root->next->next = new Node( 'B' );
$root->next->next->next = new Node( 'C' );
$root->next->next->next->next = new Node( 'D' );
$root->next->next->next->next->next = new Node( 'E' );
header("Content-type: text/plain");
unset($node);
$node = $root;
while ( $node !== NULL ) {
$node->data .= ' : Been Here 1';
$node = $node->next;
}
$node = &$root;
while ( $node !== NULL ) {
$node->data .= ' : Been Here 2';
$node = &$node->next;
}
unset($node);
$node = $root;
while ( $node !== NULL ) {
$node->data .= ' : Been Here 3';
$node = $node->next;
}
unset($node);
$node = $root;
while ( $node !== NULL ) {
echo "This node's data = '{$node->data}'\n\n";
$node = $node->next;
}
?>