Robot Posted March 5 Share Posted March 5 halo saya menetapkan tugas untuk menghapus sesi dan berhasil, dan ini adalah kode di file php <?php /** * MyBB 1.8 * Copyright 2014 MyBB Group, All Rights Reserved * * Website: http://www.mybb.com * License: http://www.mybb.com/about/license * */ function task_clearsessions($task) { global $mybb, $db, $cache, $lang, $plugins; $timeHours = 3; $cutoff = TIME_NOW - ($timeHours * 3600); $db->delete_query("sessions", "time < " . $cutoff); add_task_log($task, "The custom clear sessions task successfully ran."); } Tapi saya mencoba untuk mencoba lagi dengan jadwal This is the hidden content, please Sign In or Sign Up tapi sayangnya tidak berhasil <?php /** * MyBB 1.8 * Copyright 2014 MyBB Group, All Rights Reserved * * Website: http://www.mybb.com * License: http://www.mybb.com/about/license * */ function task_clearcaptcha($task) { global $mybb, $db, $cache, $lang, $plugins; $timeHours = 3; $cutoff = TIME_NOW - ($timeHours * 3600); $db->delete_query("captcha", "time < " . $cutoff); add_task_log($task, "The custom clear captcha task successfully ran."); } Keruntuhan berikut muncul Mengutip:Kesalahan SQL MyBB – [20] array ( ‘error_no’ => 1054, ‘error’ => ‘Unknown column \’time\’ in \’where clause\”, ‘query’ => ‘DELETE FROM mybb_searchlog WHERE time Foto ini dari Lihat Log Tugas This is the hidden content, please Sign In or Sign Up Yang bisa saya temukan hanyalah bantuan dalam memperbaiki kode dan mungkin menerapkannya ke tabel lain Quote Link to comment Share on other sites More sharing options...
Question
Robot
halo saya menetapkan tugas untuk menghapus sesi dan berhasil, dan ini adalah kode di file php
Tapi saya mencoba untuk mencoba lagi dengan jadwal
Keruntuhan berikut muncul
Foto ini dari Lihat Log Tugas
Yang bisa saya temukan hanyalah bantuan dalam memperbaiki kode dan mungkin menerapkannya ke tabel lain
Link to comment
Share on other sites
Top Posters For This Question
1
Popular Days
Mar 5
1
Top Posters For This Question
Robot 1 post
Popular Days
Mar 5 2023
1 post
0 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.