Quantcast
Viewing all articles
Browse latest Browse all 2307

[3.3.x] Support Forum • Re: Dealing with bot traffic

The first change is in session_begin in sessions.php (the four last lines is the actual change):

Code:

// if session id is setif (!empty($this->session_id)){$sql = 'SELECT u.*, s.*FROM ' . SESSIONS_TABLE . ' s, ' . USERS_TABLE . " uWHERE s.session_id = '" . $db->sql_escape($this->session_id) . "'AND u.user_id = s.session_user_id";$result = $db->sql_query($sql);$this->data = $db->sql_fetchrow($result);$db->sql_freeresult($result);            // silly bot counter-fit            if (!isset($this->data['user_id'])){                redirect("/expired.htm");            }
I gave this a try, but I found that various users (and myself on my iphone) were stuck being redirected to /expired.htm on every page they clicked through to. I think that I need to redirect them somewhere that forces a cookie purge instead.

Statistics: Posted by textkit — Wed Mar 19, 2025 9:24 pm



Viewing all articles
Browse latest Browse all 2307

Trending Articles