PHP日历 Calendar

http://www.corange.cn//uploadfiles/1197447682_59110ad5_20692.zip
http://www.corange.cn//uploadfiles/0919-2_66101.jpg

<style stype="text/css">
#cal {color:#FFF; background-color:#FFF; border: 1px solid #1a4551;font: 10px Verdana, Arial, Helvetica, sans-serif; }
#cal td { text-align:center; width: 60px;height:30px; background-color: #347a3b;}
tr#days-of-week td { background-color: #aaa;}
#cal thead td {background-color: #16414d; font-size: 12px; font-weight: bold;}
#cal thead a{ color: #FFF;}
#cal a{color: #ff0000; text-decoration:none;}
#cal .cal-prev-month-day, #cal .cal-next-month-day {color: #215f27;}
#cal-current-day {background-color: #1b5421 !important;}
</style>

<?php

// Include calendar class
require_once('calendar.class.php');
// Create calendar object
$cal = new calendar;
// Turn on navigation links
$cal->enableNavigation();
// Add event on current day
$cal->addEvent('example Event', 2007, 12, 1, 'http://www.example-event.com');
$cal->addEvent('example Event 2', 2007, 12, 2, 'http://www.example-event.com');
$cal->addEvent('example Event 3', 2007, 12, 3, 'http://www.example-event.com');
// Set innerborder to 1, this alter tables cellspacing, much easier than using CSS
$cal->setInnerBorder(1);
// Turn on non month days
$cal->enableNonMonthDays();
// Turn on pretty html output
$cal->enablePrettyHTML(TRUE);
// Display year along side month
$cal->enableYear(TRUE);
// Display calendar
$cal->display($_GET['month'], $_GET['year']);

?>
其他代码见顶部下载后测试
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值