- print_r: documentation ( source)
<?php
class Doper {
private $name;
private $id;
public function __construct($id, $name) {
$this->name = $name;
$this->id = $id;
}
public function getName() {
return $this->name;
}
/**
* Return id
* @return int
*/
public function getId() {
return $this->id;
}
}
$doper = new Doper('zuzu', 1);
echo '<pre>'; print_r($doper); exit;