Location: PHPKode > projects > News Manager - RSS aggregator > newsmanager/index.php
<?php
	/*******************************************************************************
     **  File          :  index.php                                               **
     **  Author        :  G.Ramkumar                                              **
     **  Description   :  Homepage												  **
  	 **  Date          :  14/07/2005                                              **
     **  Last Modified :  10/03/2006                                              **
     **  PHP Version   :  5.0.3                                                   **
     **                                                                           **
     *******************************************************************************/
session_start();
ob_start();
include("header.php");
flush();
if(empty($_REQUEST[lang])){
  $lang=$_SESSION[lang];
 }else{
  $lang=$_REQUEST[lang];
}
if($_REQUEST['cat_id']!="" && $_REQUEST['subcat_id']=="")
{
 $id_cat=$_REQUEST['cat_id'];
 $query_cat="select * from category where category_id=$id_cat";
 $query_res=$pg_sql->query_pass($query_cat,"4");
 $cate_naam =trim( $query_res[0]['category_name']);
 $link__= '<img src="images/arrow.gif"><a class="contlink" href="index.php?cat_id='.$id_cat.'&lang='.$lang.'">'.$cate_naam.'</a>';
 $include ='ch_spotnews.php';
 $read_include='ch_readalso.php'; 
 $read_xml_include='ch_readalso_qry.php';
}elseif($_REQUEST['cat_id']!="" && $_REQUEST['subcat_id']!=""){
 $id_cat=$_REQUEST['cat_id'];
 $id_sub=$_REQUEST['subcat_id'];
 $query_cat="select * from category where category_id=$id_cat";
 $query_res=$pg_sql->query_pass($query_cat,"4");
 $cate_naam = trim($query_res[0]['category_name']);
 $cate_link= '<img src="images/arrow.gif"><a class="contlink" href="index.php?cat_id='.$id_cat.'&lang='.$lang.'">'.$cate_naam.'</a>';

 $subquery_="select * from subcategory where subcategory_id=$id_sub";
 $subquery_res_=$pg_sql->query_pass($subquery_,"4");
 $subcate_naam = trim($subquery_res_[0]['subcategory_name']);
 $subcate_link= '&nbsp;<img src="images/arrow.gif"><a class="contlink" href="index.php?cat_id='.$id_cat.'&subcat_id='.$id_sub.'&lang='.$lang.'">'.$subcate_naam.'</a>';
 $link__=$cate_link.$subcate_link;
 $include ='ch_spotnews.php';
 $read_include='ch_readalso.php'; 
 $read_xml_include='readalso_qry.php';
}else{
  $include ='spotnews.php';
  $read_include='readalso.php';
  $read_xml_include='readalso_qry.php';
}

?>
<tr>
  <td width="180" align="left" valign="top">
		<?include("list_categories.php")?>
  </td>
  <td width="600" align="left" valign="top">
      <table width="100%" border="0" align="center" cellspacing="0" cellpadding="0">
		  <tr>
			<td align="left" valign="top" class="bgybluewolineCopy" height="17">&nbsp;&nbsp;<span class="cont_co"><?=$your_?> :</span><a class="contlink" href="http://www.belgium.be/eportal/application?languageParameter=<?=$lang?>"><?=$home_?></a>&nbsp;<img src="images/arrow.gif"><a class="contlink" href="index.php?lang=<?=$lang?>"><?=$news_?></a>&nbsp;<?=$link__?></td>
		  </tr>
     </table>
	 <table cellpadding="0" width="100%" border="0" cellpadding="3">
		 <tr>
			<td valign="top"><?include($include)?></td>
		  </tr>
		  <tr>
			 <td valign="top"><?include('cat_allnews.php')?></td>
		  </tr>
  	 </table>
 </td>
 <td width="187" align="right" valign="top">
 	<table border="0" width="110%" cellspacing="0" cellpadding="0">
     <tr>
       <td align="left" width="100%" valign="top" class="bgybluewolineCopy" height="19"></td>
     </tr>
    </table>
    <table width="100%" height="100%" border="0" cellspacing="0" cellpadding="3">
     <tr>
       <td align="left" valign="middle"><?include($read_include)?></td>
	 </tr>
	</table>
  </td>
</tr>

<?
include('footer.php');
?>
Return current item: News Manager - RSS aggregator