I typed in the following code:
Code: Select all
<?php
$object = new User;
print_r($object);
class User
{
public $name, password;
function save_user()
{
echo "Save User code goes here";
}
}
?>
Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /homepages/11/d329291176/htdocs/test.php on line 7
I even tried good code from using an example from http://php.net/, so I think I have messed up my PHP on my server? I don't know I'm getting more gray hair and I already have to much of it to begin with.
It would be very much appreciated.
Best Regards,
John
P.S. I don't know if this is the correct Category, but if not I apologize.