You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

GDPR合规中@@History/@@scroll|# Cookie的来源及用途咨询

Great question—this is a tricky one because that cookie name isn’t standard for core WordPress or most widely used plugins. Let’s break down what we can deduce and how to track down its origin:

What It Likely Does (Based on the Name)

Your initial guess is spot-on. The scroll and History keywords strongly suggest this is a functional cookie used to remember a user’s scroll position on the site. For example:

  • If a user scrolls halfway down a long page, clicks a link to another page, then uses the back button, this cookie would let the site jump back to their last scroll position instead of resetting to the top.
  • It’s almost certainly not a tracking cookie (unless the code is repurposing it for that, which is unlikely given the naming).

How to Find Its Origin

1. Core WordPress? No Way

Core WordPress never uses this naming convention. Its default cookies are all prefixed with wordpress_, wp-settings-, or wp-auth-—so this is definitely from a third-party tool or custom code.

2. Check Plugins & Themes

This is the most common source:

  • Plugin Test: Disable all plugins, refresh your site, and check if the cookie disappears. If it does, re-enable plugins one by one until the cookie comes back—you’ll find the culprit.
  • Theme Test: Switch to a default WordPress theme (like Twenty Twenty-Four). If the cookie is gone, your custom theme is generating it.
  • Code Search: Dig into your theme and plugin files (use your hosting’s file manager or a local editor) to search for setcookie (PHP) or document.cookie (JavaScript) paired with keywords like scroll, History, or the full cookie name @@History/@@scroll|#.

3. Custom Code?

It could also be a snippet added directly to your site:

  • Check your theme’s functions.php file for custom PHP cookie logic.
  • Look in your theme’s JS files (like main.js or custom.js) for frontend code that saves scroll position to a cookie.

Quick Way to Confirm Its Purpose

  1. Delete the cookie via your browser’s dev tools (Application > Cookies > Select your site > Find and delete @@History/@@scroll|#).
  2. Scroll down a page on your site, navigate away, then come back.
  3. Check if the cookie is recreated, and look at its value—if it’s a number (like 500), that’s the pixel position of your scroll. This confirms it’s purely for UX, not tracking.

内容的提问来源于stack exchange,提问作者TwoLunch

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.29 08:46:53