// 將網址替換為 Headers 頁籤中複製的 Request URL const COUNTER_API_URL = 'https://www.swsh.hlc.edu.tw/widget/visitor_counter/count_query_json.php?bid=2'; function fetchVisitorCount() { fetch(COUNTER_API_URL) .then(response => response.json()) .then(data => { // 將 JSON 數據填入您自己設計的 DOM 欄位 document.getElementById('online').innerText = data.online; document.getElementById('today').innerText = data.today; document.getElementById('yesterday').innerText = data.yesterday; document.getElementById('week').innerText = data.week; document.getElementById('month').innerText = data.month; document.getElementById('total').innerText = data.total; }) .catch(error => console.error('取得計數數據失敗:', error)); } // 頁面載入時執行 fetchVisitorCount(); // 可設定每 60 秒自動更新一次「線上人數」 setInterval(fetchVisitorCount, 60000);
第一階段:(2015)
- 接納樓無線AP建置16台。
- 孝親樓2樓無線AP建置7台。
- 專案申請平板(補助)1000台。
- 建置資訊安全網路管理器(中華電信資安艦隊3年)。




