classes breaking php5 for me

windows

Guest
this is my setup:
mac os x 10.3.7
apache 1.3.33
php 5.0.2

my actual class is much more verbose than this, but even this simple version is breaking. here's what happens. with the following code, nothing is printed to screen.


public class Zine {
public $test;
}

$myZine = new Zine;
$myZine->test = "working";
echo $myZine->test;
echo "testing";


comment out everthing but the last line, and "testing" is printed to screen. so php is working. it only dies when i try to create or instantiate a class.

is anyone else running into this? i'm kind of stuck here until i can get it working. and i can't find anything of use with google.echo = $myZine->test;


:confused: hmm wouldnt this work


echo $myZine->test;


echo = something here if it actually works never tried would echo out 0 or 1 1 for success and 0 for failurethat was a typo only on more board post not my actual code. and, no, it still doesn't work.

ps. i've corrected the initial post to reflect this.Classes can't be public (or private, or protected). If you think about it how can a class be private?of course. you're right. classes can't be public. awake too late here. i appreciate your help.
 
Back
Top