V2EX助手

V2EX助手,将v2ex.com的帖子超链接改为新窗口打开

目前為 2016-07-14 提交的版本,檢視 最新版本

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         V2EX助手
// @namespace    http://zhihaofans.com
// @version      0.2
// @description  V2EX助手,将v2ex.com的帖子超链接改为新窗口打开
// @author       zhihaofans
// @match        http://www.v2ex.com/go/*
// @match        http://www.v2ex.com/?tab=*
// @match        http://www.v2ex.com
// @grant        none
// @note         V0.1:初始版本
// @note         V0.2:更新了图标
// @icon		 http://www.v2ex.com/static/img/icon_rayps_64.png
// ==/UserScript==
$(document).ready(function(){
 	var v2ex_js_links=$("span.item_title a");
	var v2ex_js_links_num=v2ex_js_links.length;
	console.log(v2ex_js_links_num);
	for(var v2ex_js_a=0;v2ex_js_a<v2ex_js_links_num;v2ex_js_a++)
	{
		var v2ex_js_link=$("span.item_title a:eq("+v2ex_js_a+")");
		v2ex_js_link.attr("target","_blank");
	}
});