View Full Version : Pointers?

10-22-2004, 05:00 PM
Just finished a C program that sets a 'tree' data structure, that means, a struct with different data types inside of it and two pointers like this:

struct Tree{
char character;
struct Tree *Left;
struct Tree *Right;

Is there any way to do something similar in PHP? basically pointers? I was thinking about classes with references... but the manual says "References are NOT pointers".

10-22-2004, 05:52 PM
The bigger problem is that PHP does not have structures ala C , you can use classes to act for all intents and purposes as a basic structure and have other objects reference them by composition etc but despite PHP's origins you cant really map the C methodology directly to it.

Can you give an example of the sort of problem you are trying to solve ?