dounan9070 2018-01-28 20:53
浏览 162

如何制作可用性日历?

This topic is slightly related to this so PLEASE READ FIRST.

Basically now I have it so dates can be booked and I can display them on a separate page like so:

<?php
$sql = "SELECT * FROM dates";
$result = mysqli_query($conn, $sql);
?>
<body>
<h2>Current Dates Booked:</h2>
<?php
while($rows = mysqli_fetch_array($result)) {
    ?>
    <p><?php 
    echo date("l jS F", strtotime(htmlspecialchars($rows['start_date'])))
        ." - "
        .date("l jS F", strtotime(htmlspecialchars($rows['end_date']))); 
        ?>
    </p><br>
    <?php
}

mysqli_close($conn);
?>
</body>

However I want to display them on a calendar like this. Not necessarily having the same CSS with the red boxes and what not, but being able to have a calendar that updates to show what dates have already been inputted into the table to make it more user friendly and easier to read than scrolling through tons of dates printed on a screen.

However I am not sure where to start on making the calendar.

EDIT: I was able to add dates on the calendar using this method but I want to be able to block out all dates in between the two.

I have a live version of it here but not sure how to block out all dates in between

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥15 关于#python#的问题,请各位专家解答!
    • ¥15 对于这个问题的解释说明
    • ¥200 询问:python实现大地主题正反算的程序设计,有偿
    • ¥15 smptlib使用465端口发送邮件失败
    • ¥200 总是报错,能帮助用python实现程序实现高斯正反算吗?有偿
    • ¥15 对于squad数据集的基于bert模型的微调
    • ¥15 为什么我运行这个网络会出现以下报错?CRNN神经网络
    • ¥20 steam下载游戏占用内存
    • ¥15 CST保存项目时失败
    • ¥20 java在应用程序里获取不到扬声器设备