|
|
|
อยากได้โค๊ดนาฬิกาและปฏิทิน อยากได้โค๊ดนาฬิกาและปฏิทินที่ปรากฏอยู่ข้างบน เมนูแลกลิงค์คลิกที่นี้เลยจ๊า |
|
|
|
|
|
|
|
ไปอ่านดูกระทู้ที่ผ่านมานะครับ ประมาณ 20-30 กระทู้ครับ จะมีวิธีให้ Downloads ครับ
|
|
|
|
|
Date :
2 ก.พ. 2548 13:05:57 |
By :
@W_IN |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### ไฟล์ calendar.php ###
<?php
$clock .= "<TABLE width=\"100%\" border=0 cellPadding=0 cellSpacing=0>
<TBODY><TR><TD align=left><center><OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\"
codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0\"
WIDTH=\"130\" HEIGHT=\"130\" id=\"relog\" ALIGN=\"\">
<PARAM NAME=movie VALUE=\"relog.swf\">//แก้ไขพาสของไฟล์แฟลชตรงนี้ครับ ไม่รู้จะส่งให้ยังงัยลองไปหาโหลดดูครับ
<PARAM NAME=quality VALUE=high>
<PARAM NAME=bgcolor VALUE=#FFFFFF>
<param name=\"wmode\" value=\"transparent\">
<param name=\"menu\" value=\"false\">
<EMBED src=\"images/fri/relog.swf\" quality=high bgcolor=#FFFFFF WIDTH=\"130\" HEIGHT=\"130\" wmode=\"transparent\" ALIGN=\"\" TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/go/getflashplayer\" menu=\"false\">
</EMBED></OBJECT></center></TD></TR></TBODY></TABLE>";
echo $clock;
$fontfamily = isset($fontfamily) ? $fontfamily : "MS Sans Serif, Geneva, sans-serif";
$defaultfontcolor = isset($defaultfontcolor) ? $defaultfontcolor : "#5E7388";
$defaultbgcolor = isset($defaultbgcolor) ? $defaultbgcolor : "";
$todayfontcolor = isset($todayfontcolor) ? $todayfontcolor : "#FFFFFF";
$todaybgcolor = isset($todaybgcolor) ? $todaybgcolor : "#F38918";
$monthcolor = isset($monthcolor) ? $monthcolor : "#006699";
$relfontsize = isset($relfontsize) ? $relfontsize : "1";
$cssfontsize = isset($cssfontsize) ? $cssfontsize : "7pt";
$month = (isset($month)) ? $month : date("n",time());
$monthnames = array("Á¡ÃÒ¤Á","¡ØÁÀҾѹ¸ì","ÁÕ¹Ò¤Á","àÁÉÒ¹","¾ÄÉÀÒ¤Á","ÁԶعÒ¹","¡Ã¡®Ò¤Á","ÊÔ§ËÒ¤Á","¡Ñ¹ÂÒ¹","µØÅÒ¤Á","¾ÄȨԡÒ¹","¸Ñ¹ÇÒ¤Á");
$textmonth = $monthnames[$month - 1];
$year = (isset($year)) ? $year : date("Y",time());
$today = (isset($today))? $today : date("j", time());
$today = ($month == date("n",time()) && $year == date("Y",time())) ? $today : 32;
$days = date("t",mktime(1,1,1,$month,1,$year));
$dayone = date("w",mktime(1,1,1,$month,1,$year));
$daylast = date("w",mktime(1,1,1,$month,$days,$year));
$dayarray = array("ÍÒ.","¨.","Í.","¾.","¾Ä.","È.","Ê.");
$thyear=$year+543;
$content .= "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\" class=f14><tr>\n";
$content .= "<td bgcolor=\"$defaultbgcolor\" colspan=\"7\" valign=\"middle\" align=\"center\"><font color=\"$monthcolor\"><b>$textmonth $thyear</b></font></td></tr><tr>\n";
for($i=0; $i <= 6; $i++):
$width = ($i == 0 || $i == 6) ? "15%" : "14%";
$content .= " <td valign=\"middle\" width=$width\" style=\"text-align:center; background:{$defaultbgcolor}; font:bold {$cssfontsize} {$fontfamily}; color:{$defaultfontcolor};\">$dayarray[$i]</td>\n";
endfor;
$content .= "</tr>\n";
$span1 = $dayone;
$span2 = 6 - $daylast;
for($i = 1; $i <= $days; $i++):
$dayofweek = date("w",mktime(1,1,1,$month,$i,$year));
$width = ($dayofweek == 0 || $dayofweek == 6) ? "15%" : "14%";
switch ($i):
case $today:
$fontcolor = $todayfontcolor;
$bgcellcolor = $todaybgcolor;
break;
default:
$fontcolor = $defaultfontcolor;
$bgcellcolor = $defaultbgcolor;
break;
endswitch;
if($i == 1 || $dayofweek == 0):
$content .= " <tr bgcolor=\"$defaultbgcolor\">\n";
if($span1 > 0 && $i == 1)
$content .= " <td align=\"left\" bgcolor=\"$defaultbgcolor\" colspan=\"$span1\"><font face=\"null\" size=\"1\"> </font></td>\n";
endif;
$content .= " <td valign=\"middle\" width=$width\" style=\"text-align:center; background:{$bgcellcolor}; font-family:{$fontfamily}; color:{$fontcolor}; font-size:{$cssfontsize}\">$i</td>\n";
if($i == $days && $span2 > 0)
$content .= " <td align=\"left\" bgcolor=\"$defaultbgcolor\" colspan=\"$span2\"><font face=\"null\" size=\"1\"> </font></td>\n";
if($dayofweek == 6 || $i == $days)
$content .= " </tr>\n";
endfor;
$content .= "</table>\n";
echo $content;
?>
|
|
|
|
|
Date :
3 ก.พ. 2548 09:33:39 |
By :
thung |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### ไฟล์ show_calendar.php ###
## เอาโค๊ดนี้ไปแปะหน้าที่ต้องการโชว์ ##
<?
echo"<TABLE width=150>
<TR>
<TD>";
include('calendar.php');
echo"</TD>
</TR>
</TABLE>";
?>
|
|
|
|
|
Date :
3 ก.พ. 2548 09:35:38 |
By :
thung |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
แต่ว่าอันนี้..เป็นอีกแบบนะครับไม่ใช่แบบที่คุณต้องการแต่ก็ลองไปใช้ดู
|
|
|
|
|
Date :
3 ก.พ. 2548 09:36:27 |
By :
thung |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### ไฟล์ calendar.php ###
<?php
$clock .= "<TABLE width=\"100%\" border=0 cellPadding=0 cellSpacing=0>
<TBODY><TR><TD align=left><center><OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\"
codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0\"
WIDTH=\"130\" HEIGHT=\"130\" id=\"relog\" ALIGN=\"\">
<PARAM NAME=movie VALUE=\"relog.swf\">//แก้ไขพาสของไฟล์แฟลชตรงนี้ครับ ไม่รู้จะส่งให้ยังงัยลองไปหาโหลดดูครับ
<PARAM NAME=quality VALUE=high>
<PARAM NAME=bgcolor VALUE=#FFFFFF>
<param name=\"wmode\" value=\"transparent\">
<param name=\"menu\" value=\"false\">
<EMBED src=\"images/fri/relog.swf\" quality=high bgcolor=#FFFFFF WIDTH=\"130\" HEIGHT=\"130\" wmode=\"transparent\" ALIGN=\"\" TYPE=\"application/x-shockwave-flash\" PLUGINSPAGE=\"http://www.macromedia.com/go/getflashplayer\" menu=\"false\">
</EMBED></OBJECT></center></TD></TR></TBODY></TABLE>";
echo $clock;
$fontfamily = isset($fontfamily) ? $fontfamily : "MS Sans Serif, Geneva, sans-serif";
$defaultfontcolor = isset($defaultfontcolor) ? $defaultfontcolor : "#5E7388";
$defaultbgcolor = isset($defaultbgcolor) ? $defaultbgcolor : "";
$todayfontcolor = isset($todayfontcolor) ? $todayfontcolor : "#FFFFFF";
$todaybgcolor = isset($todaybgcolor) ? $todaybgcolor : "#F38918";
$monthcolor = isset($monthcolor) ? $monthcolor : "#006699";
$relfontsize = isset($relfontsize) ? $relfontsize : "1";
$cssfontsize = isset($cssfontsize) ? $cssfontsize : "7pt";
$month = (isset($month)) ? $month : date("n",time());
$monthnames = array("Á¡ÃÒ¤Á","¡ØÁÀҾѹ¸ì","ÁÕ¹Ò¤Á","àÁÉÒ¹","¾ÄÉÀÒ¤Á","ÁԶعÒ¹","¡Ã¡®Ò¤Á","ÊÔ§ËÒ¤Á","¡Ñ¹ÂÒ¹","µØÅÒ¤Á","¾ÄȨԡÒ¹","¸Ñ¹ÇÒ¤Á");
$textmonth = $monthnames[$month - 1];
$year = (isset($year)) ? $year : date("Y",time());
$today = (isset($today))? $today : date("j", time());
$today = ($month == date("n",time()) && $year == date("Y",time())) ? $today : 32;
$days = date("t",mktime(1,1,1,$month,1,$year));
$dayone = date("w",mktime(1,1,1,$month,1,$year));
$daylast = date("w",mktime(1,1,1,$month,$days,$year));
$dayarray = array("ÍÒ.","¨.","Í.","¾.","¾Ä.","È.","Ê.");
$thyear=$year+543;
$content .= "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\" class=f14><tr>\n";
$content .= "<td bgcolor=\"$defaultbgcolor\" colspan=\"7\" valign=\"middle\" align=\"center\"><font color=\"$monthcolor\"><b>$textmonth $thyear</b></font></td></tr><tr>\n";
for($i=0; $i <= 6; $i++):
$width = ($i == 0 || $i == 6) ? "15%" : "14%";
$content .= " <td valign=\"middle\" width=$width\" style=\"text-align:center; background:{$defaultbgcolor}; font:bold {$cssfontsize} {$fontfamily}; color:{$defaultfontcolor};\">$dayarray[$i]</td>\n";
endfor;
$content .= "</tr>\n";
$span1 = $dayone;
$span2 = 6 - $daylast;
for($i = 1; $i <= $days; $i++):
$dayofweek = date("w",mktime(1,1,1,$month,$i,$year));
$width = ($dayofweek == 0 || $dayofweek == 6) ? "15%" : "14%";
switch ($i):
case $today:
$fontcolor = $todayfontcolor;
$bgcellcolor = $todaybgcolor;
break;
default:
$fontcolor = $defaultfontcolor;
$bgcellcolor = $defaultbgcolor;
break;
endswitch;
if($i == 1 || $dayofweek == 0):
$content .= " <tr bgcolor=\"$defaultbgcolor\">\n";
if($span1 > 0 && $i == 1)
$content .= " <td align=\"left\" bgcolor=\"$defaultbgcolor\" colspan=\"$span1\"><font face=\"null\" size=\"1\"> </font></td>\n";
endif;
$content .= " <td valign=\"middle\" width=$width\" style=\"text-align:center; background:{$bgcellcolor}; font-family:{$fontfamily}; color:{$fontcolor}; font-size:{$cssfontsize}\">$i</td>\n";
if($i == $days && $span2 > 0)
$content .= " <td align=\"left\" bgcolor=\"$defaultbgcolor\" colspan=\"$span2\"><font face=\"null\" size=\"1\"> </font></td>\n";
if($dayofweek == 6 || $i == $days)
$content .= " </tr>\n";
endfor;
$content .= "</table>\n";
echo $content;
?>
|
|
|
|
|
Date :
22 มี.ค. 2551 15:19:52 |
By :
22 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
เจ๋งเป้ง
|
|
|
|
|
Date :
2011-02-14 17:05:59 |
By :
hotmail |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
sadfgfghdfhsdgsf
|
|
|
|
|
Date :
2013-03-25 14:55:12 |
By :
qwert |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Load balance : Server 01
|