<?php
header("content-type:text/html;charset=utf-8");
class nn//這段程式碼很顯然,其子類別就自動呼叫了父類別的建構(gòu)方法。 。 。 。
{
? public $name;
? public function __construct()
? {
? ? echo '我是在nn類別裡面的構(gòu)造函數(shù)! <br>';
? ? //$this->name=$iname;
? }
#}
class mm extends nn
{
#}
$p=new mm;
##?> ;