<?php 
session_start();
if (!defined('YEE_ROOT'))
	define('YEE_ROOT', './admin/');
	
	require_once YEE_ROOT.'include/essentials.php';

	//- get the db object
	global $db;
$p_count = list_news_count();
$cur_page = $_GET['p'];
$page_url  = 'index.php?p=';

$pages_set = show_pages_for_front($cur_page,$p_count,$page_url);
$news = list_news_for_front($cur_page,$p_count);
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>衛斯理幼稚園</title>
<link rel=stylesheet type="text/css" href="style.css"/>
<style type="text/css">
<!--
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
-->
</style>
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
<script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
</head>

<body onLoad="MM_preloadImages('img_button/button_N1_1.gif','img_button/button_N2_1.gif','img_button/button_N3_1.gif','img_button/button_N4_1.gif','img_button/button_N5_1.gif','img_button/button_N6_1.gif','img_button/button_N7_1.gif','img_button/button_N8_1.gif')">
<table width="1100" height="240" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="1100" height="240">
      <param name="movie" value="fla.swf/img.swf">
      <param name="quality" value="high">
      <embed src="fla.swf/img.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="1100" height="240"></embed>
    </object></td>
  </tr>
</table>
<table width="1100" height="70" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#0099FF">
  <tr>
    <td width="15">&nbsp;</td>
    <td width="70"><a href="index.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image13','','img_button/button_N1_1.gif',1)"><img src="img_button/button_N1.gif" name="Image13" width="70" height="70" border="0"></a></td>
    <td width="145"><a href="about.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image12','','img_button/button_N2_1.gif',1)"><img src="img_button/button_N2.gif" name="Image12" width="145" height="70" border="0"></a></td>
    <td width="145"><a href="environment.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image11','','img_button/button_N3_1.gif',1)"><img src="img_button/button_N3.gif" name="Image11" width="145" height="70" border="0"></a></td>
    <td width="145"><a href="academics_eng1.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image10','','img_button/button_N4_1.gif',1)"><img src="img_button/button_N4.gif" name="Image10" width="145" height="70" border="0"></a></td>
    <td width="145"><a href="academics-1.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image9','','img_button/button_N5_1.gif',1)"><img src="img_button/button_N5.gif" name="Image9" width="145" height="70" border="0"></a></td>
    <td width="145"><a href="photo.php" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image8','','img_button/button_N6_1.gif',1)"><img src="img_button/button_N6.gif" name="Image8" width="145" height="70" border="0"></a></td>
    <td width="145"><a href="enroll.html" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('Image7','','img_button/button_N7_1.gif',1)"><img src="img_button/button_N7.gif" name="Image7" width="145" height="70" border="0"></a></td>
    <td width="145"><a href="video.html" target="_blank" onMouseOver="MM_swapImage('Image6','','img_button/button_N8_1.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="img_button/button_N8.gif" name="Image6" width="145" height="70" border="0"></a></td>
  </tr>
</table>
<table id="content" width="1100" height="380" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="550" valign="top"><div id="about">
      <!--
		<table width="505" height="357" border="0" cellpadding="0" cellspacing="0">
		<tr>
		  <td class="word" align=middle>
			<IFRAME name=show src="http://218.32.77.182/wesleykids/kids/cf2.html" frameBorder=0 width=480  scrolling=no height=340 ></IFRAME></td>
		</tr>
		</table>
		-->
      <iframe name=show src="http://218.32.77.182/wesleykids/kids/cf2.html" frameborder=0 width=480  scrolling=no height=340 ></iframe>
    </div></td>
    <td width="550"><div id="right"> <table width="505" height="357" border="0" cellpadding="0" cellspacing="0">
        <tr>
          <td class="newslist"><table width="465" border="0" cellspacing="0" cellpadding="0">
          	<?php 
      		if($news && count($news))
      		{
      			foreach ($news as $each_news)
      			{	
      		?>
            <tr>
              <td width="23"><img src="img_index/news-icon.gif" width="10" height="10" /></td>
              <td width="307"><a href="news.php?id=<?php echo $each_news['id'];?>"><?php echo $each_news['name'];?></a></td>
              <td width="135"><?php echo date($yee_config['o_date_format'],$each_news['update_time']);?></td>
            </tr>       			
      		<?php
      			}
      		}
          	?>
            
          </table>
            <table width="465" height="30" border="0" cellpadding="0" cellspacing="0">
              <tr>
                <td valign="bottom"><div id="choose"><?=$pages_set?></div></td>
              </tr>
            </table>
            <br></td>
        </tr>
      </table>
    </div></td>
  </tr>
</table>
<table width="1100" height="70" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td><img src="img_index/footer.gif" width="1100" height="70"></td>
  </tr>
</table>
</body>
</html>




