What would be the best way to actually remove the object from the linked list here rather then hide it?

PHP Code:
<?php
class Attribute {

    protected 
$name;
    protected 
$value;
    
    protected 
$attribute;
    
    protected 
$active true;
    
    public function 
__construct($name='',$value='') {
    
        
$this->setName($name);
        
$this->setValue($value);
    
    }
    
    public function 
setName($name) {
    
        
$this->name $name;
    
    }
    
    public function 
setValue($value) {
    
        
$this->value $value;
    
    }
    
    public function 
getName() {
    
        return 
$this->name;
    
    }
    
    public function 
getValue() {
    
        return 
$this->value;
    
    }
    
    public function 
addAttribute($name,$value) {
    
        if(
$this->attribute) {
        
            
$this->attribute->addAttribute($name,$value);
        
        } else {
        
            
$this->attribute = new Attribute($name,$value);
        
        }
        
        return 
$this;
    
    }
    
    public function 
removeAttribute($name) {
    
        if(
strcasecmp($this->getName(),$name)==0) {
            
$this->active false;
        }
    
        if(
$this->attribute) {
        
            
$this->attribute->removeAttribute($name);
        
        }
        
        return 
$this;
    
    }
    
    public function 
render() {
    
        
$str $this->active?$this->getName().'="'.$this->getValue().'"':'';
        
        if(
$this->attribute) {
            
            
$str.= ' '.$this->attribute->render();
            
        }
        
        return 
$str;
    
    }

}
PHP Code:
$attribute = new Attribute('id','order-form');

echo

$attribute

->addAttribute('class','form')
->
addAttribute('method','post')
->
addAttribute('action','/index.php')

->
removeAttribute('class')
->
removeAttribute('action')

->
render();