".$acat[name]."
"; if (true){ $where = ' AND a.category = \''.$acat[id].'\' '; $sql = 'SELECT a.section, a.category, a.id, a.header, a.short_detail, a.keyword, a.detail, a.slug, a.icon , f.group_name file_group_name, f.name file_name, f.detail file_detail, f.file_name file_file_name , f.keyword file_keyword FROM a_news a INNER JOIN a_news_file f ON a.id=f.ref_id AND f.ref_type=\'NEWS\' '.$where.' WHERE a.published=1 AND a.status=\'A\' AND f.status=\'A\' AND f.ref_type=\'NEWS\' '.$where.' ORDER BY a.news_date DESC, a.id , f.seq, f.id'; //echo '
'.$sql.'
'; $query = mysql_query($sql); $num_rows=mysql_num_rows($query); if ($num_rows>0){ $a=0; $file_group_name = ''; $news_id=0; while($a<$num_rows){ $row = mysql_fetch_array($query); $url = 'content_journal.php?id='.$row[id].'&rk='.$row[rand_key].'&slug='.$row[slug]; if ($news_id!=$row[id]){ $news_id = $row[id]; if ($a>0) { echo "
\n\n\n"; echo '


'; }//end if echo "\n\n\n
\n"; echo "
\n"; if ($row[icon]!="") { echo ''; }else{ } echo "
\n"; echo "
\n"; echo '
'.$row[header].'
'; echo '
'.$row[short_detail].'
'; if (trim($row[keyword])!="") echo '
Keywords: '.$row[keyword].'
'; $file_group_name = ""; }//end if if ($file_group_name!=trim($row[file_group_name])){ $file_group_name = trim($row[file_group_name]); if ($a>0) echo '

'; echo '
'.$file_group_name.'
'; }//end if if ($row[file_file_name]!=""){ $path_file = $path_news_file.$row[file_file_name]; if (file_exists($path_file)){ $file_size=formatFileSizeUnits(filesize($path_file)); }else{ $file_size = "0 bytes"; } $download_file = 'download PDF ('.$file_size.')'; }else{ $download_file=''; } echo '
'; echo '
'.$row[file_name].'
'; echo '
'.string2html($row[file_detail]).'
'; echo '
'.$download_file.'
'; if (trim($row[file_keyword])!="") echo '
Keywords: '.$row[file_keyword].'
'; echo '
'; echo "
"; $a++; }//end while if ($a>0) { echo "\n
\n\n"; echo '


'; }//end if }else{ echo '
record not found!
'; }//end if }else{ } //end if }else{ echo '
Category not found!
'; }//end if echo '





'; showtail($root,$param); require("inc_admin_close.php"); ?>