bing/baidu搜索字符转义错误重复刷新问题
Resolved#1432ttwjzCreated at 3 months ago

当搜索字符串包含'时(即url编码%27)时,bing或baidu的搜索结果重复刷新。bug稳定复现。

  •         // 处理Bing搜索URL (包括国际版)
            if (settings.enableBing && (urlObj.hostname === 'cn.bing.com' || urlObj.hostname === 'www.bing.com') && urlObj.pathname === '/search') {
                const searchQuery = urlObj.searchParams.get('q');
                const firstParam = urlObj.searchParams.get('first');
    
                if (searchQuery) {
                    // 使用URLSearchParams避免手工拼接
                    const params = new URLSearchParams();
                    params.append('q', searchQuery);
    
                    if (firstParam) {
                        params.append('first', firstParam);
                    }
                    // 保持原始域名不变
                    let newUrl = `https://${urlObj.hostname}/search?${params.toString()}`;
                    // let newUrl = `https://${urlObj.hostname}/search?q=${encodeURIComponent(searchQuery)}`;
                    // if (firstParam) {
                    //     newUrl += `&first=${firstParam}`;
                    // }
                    ......
    

    BIng模块已尝试修复。

  • 已复现。

  • 已解决。

  • smallbedrockI
    3 months agoclosed the feedback
  • 360搜索也存在此类问题,可以考虑修复。

  • ttwjz
    3 months agoclosed the feedback
  • 360搜索也存在此类问题,可以考虑修复。

  • ttwjz
    3 months agoreopened the feedback
  • 已了解,考虑到这引擎几乎没人用,已经编写好更新,但防止多次更新的烦扰,下周正式更新

No data
Login to comment
Labels
Watch
Participants