{@ $comment_items = $item->getComment()}
{@ $comment_srls = Array()}
{@ $parent_num = Array()}
{@ $p = Array()}
{@ $p[0]=0}
{@ $parent_num[$c_item->comment_srl] = 1}
{@ $comment_srls[0][$p[0]] = $c_item->comment_srl}
{@ $p[0]++}
{@ $p[$c]=0}
{@ $parent_num[$c_item->comment_srl] = ($c+1)}
{@ $comment_srls[$c][$p[$c]] = $c_item->comment_srl}
{@ $p[$c]++}
{@ $c_count=1}
{@ $comment_title = strip_tags($c_item->content)}
{@ $comment_title = trim(cut_str($comment_title, ($widget_info->content_cut_size-($parent_num[$c_item->comment_srl]*10)), '...'))}
{@ $c_count++}
{@ $c_obj->document_srl = $item->get('document_srl')}
{@ $c_obj->sort_index = 'list_order'}
{@ $c_obj->order_type = 'desc'}
{@ $c_obj->list_count = $widget_info->comment_count*list_count*page_count}
{@ $comment_output = executeQueryArray('widgets.widget_kgcontent.getNewestComments', $c_obj)}
{@ $comment_items = $comment_output->data}
{@ $comment_srls = Array()}
{@ $parent_num = Array()}
{@ $p = Array()}
{@ $p[0]=0}
{@ $parent_num[$c_item->comment_srl] = 1}
{@ $comment_srls[0][$p[0]] = $c_item->comment_srl}
{@ $p[0]++}
{@ $p[$c]=0}
{@ $parent_num[$c_item->comment_srl] = ($c+1)}
{@ $comment_srls[$c][$p[$c]] = $c_item->comment_srl}
{@ $p[$c]++}
{@ $parent_srls = Array()}
{@ $parent_srls[] = $c_item->parent_srl}
{@ $comment_srls = Array()}
{@ $comments = Array()}
{@ $comment_srls[] = $c_item->comment_srl}
{@ $comments[$c_item->comment_srl] = $c_item}
{@ $last_srls = Array()}
{@ $exist_srl = 0}
{@ $exist_srl++}
{@ $last_srls[] = $comment_srls[$c]}
{@ $final_srls = Array()}
{@ $exist_srl = 0}
{@ $comment_srl = $last_srls[$c]}
{@ $exist_srl = 1}
{@ $comment_srl = $comments[$comment_srl]->parent_srl}
{@ $final_srls[] = $last_srls[$c]}
{@ $temp_final_comments = Array()}
{@ $comment_srl = $final_srls[$c]}
{@ $equal_srl = 0}
{@ $temp_final_comments[$c][$comment_srl] = $comments[$comment_srl]}
{@ $equal_srl = 1}
{@ $temp_final_comments[$c][$comment_srl] = $comments[$comment_srl]}
{@ $comment_srl = $comments[$comment_srl]->parent_srl}
{@ $final_comments = Array()}
{@ $temp_final_comments[$c] = array_reverse($temp_final_comments[$c])}
{@ $final_comments[$f_item->comment_srl] = $f_item}
{@ $c_count=1}
{@ $comment_title = strip_tags($f_item->content)}
{@ $comment_title = trim(cut_str($comment_title, ($widget_info->content_cut_size-(($parent_num[$f_item->comment_srl]-$parent_num[$item->get('comment_srl')])*10)), '...'))}
{@ $c_count++}