| Re: problem with getAllChild |
| by trabis on 2009/8/20 17:21:39 Try this: |
| Re: problem with getAllChild |
| by trabis on 2009/8/20 16:58:52 Damn, this is hard. Since we add extra value on the query you have to fix this: le="color: #000000"><?php while (list($catid, $pid, $name) = $xoopsDB->fetchRow($result))
|
| Re: problem with getAllChild |
| by urbanspacema on 2009/8/20 16:56:42 fixed but the problem is not that ... I still do not see the child |
| Re: problem with getAllChild |
| by trabis on 2009/8/20 16:49:54 Of course, your query is not asking it. le="color: #000000"><?php $sql = "SELECT `$id_name`, `$pid_name`, `$title_name` FROM ".$xoopsDB->prefix."_"."$table WHERE `$pid_name`= 0" ; It needs to go on the row for the Object to work. |
| Re: problem with getAllChild |
| by urbanspacema on 2009/8/20 16:40:13 mmm don't work... if i print print_r($objsArray); it return this le="color: #000000"><?php Array ( [0] => XoopsDummyObject Object ( [vars] => Array ( [topic_id] => Array ( [value] => 2 [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_pid] => Array ( [value] => [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_title] => Array ( [value] => Categoria news [required] => [data_type] => 1 [maxlength] => [changed] => [options] => ) ) [cleanVars] => Array ( ) [_isNew] => [_isDirty] => [_errors] => Array ( ) [_filters] => Array ( ) ) ) Array ( [0] => XoopsDummyObject Object ( [vars] => Array ( [topic_id] => Array ( [value] => 2 [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_pid] => Array ( [value] => [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_title] => Array ( [value] => Categoria news [required] => [data_type] => 1 [maxlength] => [changed] => [options] => ) ) [cleanVars] => Array ( ) [_isNew] => [_isDirty] => [_errors] => Array ( ) [_filters] => Array ( ) ) [1] => XoopsDummyObject Object ( [vars] => Array ( [topic_id] => Array ( [value] => 1 [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_pid] => Array ( [value] => [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_title] => Array ( [value] => XOOPS [required] => [data_type] => 1 [maxlength] => [changed] => [options] => ) ) [cleanVars] => Array ( ) [_isNew] => [_isDirty] => [_errors] => Array ( ) [_filters] => Array ( ) ) ) Array ( ) Array ( [0] => XoopsDummyObject Object ( [vars] => Array ( [topic_id] => Array ( [value] => 1 [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_pid] => Array ( [value] => [required] => [data_type] => 3 [maxlength] => [changed] => [options] => ) [topic_title] => Array ( [value] => Categoria ams [required] => [data_type] => 1 [maxlength] => [changed] => [options] => ) ) [cleanVars] => Array ( ) [_isNew] => [_isDirty] => [_errors] => Array ( ) [_filters] => Array ( ) ) ) Array ( ) Value for topic_pid is always empty... |