PHP Classes

correction to code

Recommend this page to a friend!

      PHP TreeView  >  All threads  >  correction to code  >  (Un) Subscribe thread alerts  
Subject:correction to code
Summary:A minor correction in code
Messages:2
Author:Milind More
Date:2012-01-17 09:31:36
Update:2013-10-18 07:14:01
 

  1. correction to code   Reply   Report abuse  
Picture of Milind More Milind More - 2012-01-17 09:31:36
As we are taking $idField in function
public function __construct($host, $userName, $password, $dbName, $tableName, $idField, $titleField, $parentIdField,$prefix)
.....
...
..
.
and passing and default primary key 'id'
$this->queryArray[$row['id']] = array(
'id' => $row[$idField],
'title' => $row[$titleField],
'parent_id' => $row[$parentIdField]
);
}
}
so it should be like
$this->queryArray[$row[$idField]] = array(
'id' => $row[$idField],
'title' => $row[$titleField],
'parent_id' => $row[$parentIdField]
);
}
}
Rest Work Fine for Me thanks for your efforts please give example so other dump pepole can understand this code

  2. Re: correction to code   Reply   Report abuse  
Picture of Rafa? Wiatrowski Rafa? Wiatrowski - 2013-10-18 07:14:01 - In reply to message 1 from Milind More
Hi,

Tree works great, but I need links.
Do you know a way to insert html links ?

Kind regards,
Rafał