找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
热搜: 活动 交友 discuz
查看: 2569|回复: 7

怎么让新标签打开新页面时,自动跳转至新的页面?

[复制链接]

3

主题

4

回帖

43

积分

新手上路

积分
43
发表于 2020-7-5 10:33:47 | 显示全部楼层 |阅读模式
怎么让新标签打开新页面时,自动跳转至新的页面?
我看设置,没有有效的设置,能否告知下,怎么做。
感谢
回复

使用道具 举报

9

主题

8128

回帖

2万

积分

超级版主

(^^ゞ

积分
22794
发表于 2020-7-5 12:23:15 | 显示全部楼层
你是指的在新标签页上以新建前台标签的形式打开快捷方式吗?
目前还没有这个设置项,目前可能通过组合键的方式实现,如:使用鼠标中键或按住 Ctrl 点击左键将在新建的后台标签中打开网页;按住 Shift 点击左键将在新窗口中打开网页;按住 Ctrl + Shift 点击左键将在新建的前台标签中打开网页。
¯\(°_o)/¯
回复

使用道具 举报

匿名  发表于 2020-7-5 20:27:07
这样子行吗
Snipaste_2020-07-05_20-26-44.png
回复

使用道具

41

主题

6120

回帖

2万

积分

管理员

积分
21299
发表于 2020-7-6 00:10:48 | 显示全部楼层
默认不就是自动跳转至新的页面么?
QQ(2530160833)
回复

使用道具 举报

13

主题

41

回帖

613

积分

高级会员

积分
613
发表于 2025-1-22 06:16:01 | 显示全部楼层
本帖最后由 vrgf1ew 于 2025-1-22 07:37 编辑
S8F8ry 发表于 2020-7-5 12:23
你是指的在新标签页上以新建前台标签的形式打开快捷方式吗?
目前还没有这个设置项,目前可能通过组合键的 ...

问下有什么方法可以实现ctrl点击链接后自动跳转到对应页面,其实就是ctrl shift点击的效果,我用ctrl点击习惯了,每次用ctrl shift点击都要反应下。
回复

使用道具 举报

9

主题

8128

回帖

2万

积分

超级版主

(^^ゞ

积分
22794
发表于 2025-1-22 13:01:36 | 显示全部楼层
vrgf1ew 发表于 2025-1-22 06:16
问下有什么方法可以实现ctrl点击链接后自动跳转到对应页面,其实就是ctrl shift点击的效果,我用ctrl点击 ...

有一个油猴脚本可以实现类似的功能:Open links in new tab,它默认是直接点击链接就在新标签页中打开并激活;如果你是想保留直接点击的默认行为,只是改动 Ctrl+单击 的行为,可以自己将脚本修改成下面这样:

  1. // ==UserScript==
  2. // @name         Open links in new tab
  3. // @description  Open links in new tab. Ctrl-click or Middle-click loads it in background
  4. // @include      *
  5. // @namespace    wOxxOm.scripts
  6. // @author       wOxxOm
  7. // @version      2.0.5
  8. // @license      MIT License
  9. // @grant        GM_openInTab
  10. // @run-at       document-start
  11. // @downloadURL https://update.greasyfork.org/scripts/12367/Open%20links%20in%20new%20tab.user.js
  12. // @updateURL https://update.greasyfork.org/scripts/12367/Open%20links%20in%20new%20tab.meta.js
  13. // ==/UserScript==

  14. var suppressing, clickedElement;

  15. window.addEventListener('mousedown', function (e) {
  16.   clickedElement = e.target;
  17. }, true);

  18. window.addEventListener('mouseup', function (e) {
  19.   if (!e.ctrlKey || e.button > 1 || e.altKey || e.target != clickedElement)
  20.     return;
  21.   var link = e.target.closest('a');
  22.   if (!link ||
  23.       (link.getAttribute('href') || '').match(/^(javascript|#|$)/) ||
  24.       link.href.replace(/#.*/, '') == location.href.replace(/#.*/, '')
  25.   )
  26.     return;

  27.   GM_openInTab(link.href, {
  28.     active: !e.button,
  29.     setParent: true,
  30.     insert: true,
  31.   });
  32.   suppressing = true;
  33.   setTimeout(function () {
  34.     window.dispatchEvent(new MouseEvent('mouseup', {bubbles: true}));
  35.   });
  36.   prevent(e);
  37. }, true);

  38. window.addEventListener('click', prevent, true);
  39. window.addEventListener('auxclick', prevent, true);

  40. function prevent(e) {
  41.   if (!suppressing)
  42.     return;
  43.   e.preventDefault();
  44.   e.stopPropagation();
  45.   e.stopImmediatePropagation();
  46.   setTimeout(function () {
  47.     suppressing = false;
  48.   }, 100);
  49. }
复制代码


¯\(°_o)/¯
回复

使用道具 举报

45

主题

409

回帖

2548

积分

金牌会员

积分
2548
发表于 2025-1-22 18:11:30 | 显示全部楼层
vrgf1ew 发表于 2025-1-22 06:16
问下有什么方法可以实现ctrl点击链接后自动跳转到对应页面,其实就是ctrl shift点击的效果,我用ctrl点击 ...

送你一个ahk脚本:Ctrl+左键替换成Ctrl+shift+左键.ahk
  1. ; Ctrl+左键替换成Ctrl+shift+左键
  2. #Requires AutoHotkey v2.0
  3. #SingleInstance

  4. if WinActive("ahk_class Chrome_WidgetWin_1") {

  5.         ^LButton::{
  6.                 Send "{Ctrl down}{Shift down}{LButton}{Ctrl up}{Shift up}"
  7.         }

  8. }
复制代码


回复

使用道具 举报

13

主题

41

回帖

613

积分

高级会员

积分
613
发表于 2025-1-24 22:12:43 | 显示全部楼层
S8F8ry 发表于 2025-1-22 13:01
有一个油猴脚本可以实现类似的功能:Open links in new tab,它默认是直接点击链接就在新标签页中打开并 ...

试了下,的确有效。多谢!
回复

使用道具 举报

高级模式
B Color Image Link Quote Code Smilies

本版积分规则

Archiver|手机版|小黑屋|百分浏览器论坛

GMT+8, 2025-6-9 06:32 , Processed in 0.021863 second(s), 22 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表