<?php
class rectangle
{ var $height;
var $width;
function __construct($arg1, $arg2)
{
$this->height=$arg1;
$this->width=$arg2; }
function show()
{
echo "Height=$this->height Width=$this->width";
}
function __destruct()
{
echo "<br> Object is Destroyed";
} }
$obj=new rectangle(10,20);
$obj->show();
?>
0 Comments