Greasy Fork

Greasy Fork is available in English.

淘宝天猫、京东优惠券、拼多多一键领取,支持全网搜索,实实在在省钱。淘宝618活动开启

淘宝天猫内部优惠券一键领取,在淘宝、淘宝商品页购买按钮下方可以直接领取相关商品优惠券,还支持按名称搜索全网相关商品,不满意的可以使用全网搜索功能搜索商品关键字,注意搜索词需要尽量简短,支持筛选。新增京东优惠券领取。添加拼多多领券,增加优惠券领取app下载。

当前为 2021-06-01 提交的版本,查看 最新版本

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name         淘宝天猫、京东优惠券、拼多多一键领取,支持全网搜索,实实在在省钱。淘宝618活动开启
// @namespace    https://tk.xunhuo.vip
// @version      1.39.5
// @description  淘宝天猫内部优惠券一键领取,在淘宝、淘宝商品页购买按钮下方可以直接领取相关商品优惠券,还支持按名称搜索全网相关商品,不满意的可以使用全网搜索功能搜索商品关键字,注意搜索词需要尽量简短,支持筛选。新增京东优惠券领取。添加拼多多领券,增加优惠券领取app下载。
// @icon         https://tk.xunhuo.vip/favicon.ico
// @author       优惠券
// @connect      xunhuo.vip
// @include      *detail.tmall.com/*
// @include      *item.taobao.com/*
// @include      *list.tmall.com/*
// @include      *s.taobao.com/*
// @include      *chaoshi.detail.tmall.com/*
// @include      *detail.tmall.hk/*
// @include      *list.tmall.hk/*
// @include      *item.jd.com/*
// @include      *jd.hk/*
// @include      *youhui.pinduoduo.com/*
// @include      https://tk.xunhuo.vip/api_gaoyong_url_m.aspx*
// @homepageURL       https://tk.xunhuo.vip/?id=24557
// @require      https://cdn.bootcdn.net/ajax/libs/jquery/1.7.2/jquery.min.js
// @match        https://tk.xunhuo.vip/api_gaoyong_url_m.aspx
// @grant        none
// ==/UserScript==
//https://cdn.bootcss.com/jquery/2.2.4/jquery.min.js
(function() {
    'use strict';
        $(document).ready(function() {
		var url = window.location.host;
        var name = '';//名称 $(document).attr('title');
        var id = '';
            //淘宝商品
		if (url == 'item.taobao.com') {
            id = $("link[rel=canonical]").attr("href");
            id = id.split("id=")[1];
            name = $('.tb-main-title').attr('data-title');
           var qurl="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword=";

            var taobao = '<div class="tb-btn-buy" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(id) +'" title="进入后请选择浏览器打开" target="_blank">领取优惠券</a></div><div class="tb-btn-add" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(name) +'"  title="搜索全部宝贝,如果想要搜索到更多商品,请修改搜索关键字,尽量简短,因为很多商家为了做优化添加了很多无用的词,造成无法搜索到更多商品。!" target="_blank">全网搜券</a></div>';
           //var taobao2 = '<div class="tb-btn-buy" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/jiudianjiu.aspx?id=24557" target="_blank">九块九包邮</a></div><div class="tb-btn-add" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/jingxuan.aspx?id=24557" target="_blank">每日精选</a></div>';
           var taobao2 = '<div class="tb-btn-buy" style="padding-top:10px;"><a href="https://s.click.taobao.com/JL6PHnu" title="每天可领取三次" target="_blank">淘宝618红包领取</a></div><div class="tb-btn-add" style="padding-top:10px;"><a href="https://u.jd.com/z0YpGNs" title="每天可领取三次" target="_blank">京东618红包领取</a></div>';
             var taobao3 = '<div class="tb-btn-buy" style="padding-top:10px;"><a href="https://jk.xunhuo.vip/?ah=total&kw='+ encodeURI(name) +'" target="_blank" title="搜索京东有优惠券的商品,请自行输入关键字,尽量简短。">京东搜索</a></div><div class="tb-btn-add" style="padding-top:10px;"><a href="https://youhui.pinduoduo.com/search/landing?keyword='+ encodeURI(name) +'&pid=1687692_15178080&cpsSign=CM_200617_1687692_15178080_73246e704c0b4a7cc45c9fbf914dc98c&duoduo_type=2" target="_blank" title="搜索不到或商品较少,请自行修改关键字,尽量简短。">拼多多搜索</a></div>';
            var taobao4 = '<style>a.xunhuoapp{position: relative;font-size: 25px;}.xunhuoapp img.qrcode{position:absolute;z-index:99;top:-135px;width:7.5rem;max-width:none;height:7.5rem;transform:scale(0);transform-origin:top right;opacity:0;border:.3125rem solid #0085ba;border-radius:.25rem;-webkit-transition:all .4s ease-in-out;-o-transition:all .4s ease-in-out;transition:all .4s ease-in-out;}.xunhuoapp:hover img.qrcode{transform:scale(1);opacity:1;}</style><div class="xunhuo" style="padding-top: 250px;"><a class="xunhuoapp" href="javascript:" role="button" data-spm-anchor-id="a220o.1000855.0.0"><img class="xunhuoapp qrcode" src="https://tvax1.sinaimg.cn/large/63953719gy1ggbgh6ripyj208c08c749.jpg" alt="领券版app">领券版app下载</a></div>';
            var taobao5 = '<div class="xunhuo" style="padding-top: 20px;"><a class="xunhuoapp" href="javascript:"><img class="xunhuoapp qrcode" src="https://api.qrserver.com/v1/create-qr-code/?data='+ encodeURIComponent(qurl) +''+ encodeURI(name) +'" ><p style="color: #F40;">扫码领券</p></a><a class="xunhuoapp" href="javascript:"><img class="xunhuoapp qrcode" src="https://api.qrserver.com/v1/create-qr-code/?data=https://tk.xunhuo.vip/m/?id=24557" >手机网页领券版(扫码后,保存书签)</a></div>';

            $('.tb-action').append(taobao,taobao2,taobao3,taobao4,taobao5);
		}
        //天猫商品
        else if(url == 'detail.tmall.com'){
            id = $("link[rel=canonical]").attr("href");
            id = id.split("id=")[1];
            name = $('meta[name=keywords]').attr('content');

            var so="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword=";
            var tmall =   '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(id) +'" title="进入后请选择浏览器打开" target="_blank">领取优惠券</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(name) +'" title="点这里可以搜索全部店铺相同名称的全部宝贝,如果想要搜索到更多商品,请修改搜索关键字,尽量简短,因为很多商家为了做优化添加了很多无用的词,造成无法搜索到更多商品。!" target="_blank">全网搜券</a></div>';

            var tmall2 =   '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://s.click.taobao.com/JL6PHnu" title="每天可领取三次" target="_blank">淘宝618红包领取</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://u.jd.com/z0YpGNs" title="每天可领取三次" target="_blank">京东618红包领取</a></div>';

            //var tmall2 =   '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/jiudianjiu.aspx?id=24557" target="_blank">九块九包邮</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/jingxuan.aspx?id=24557" target="_blank">每日精选</a></div>';
            var tmall3 =   '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://jk.xunhuo.vip/?ah=total&kw='+ encodeURI(name) +'" target="_blank" title="搜索京东有优惠券的商品,请自行输入关键字,尽量简短。">京东搜索</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://youhui.pinduoduo.com/search/landing?keyword='+ encodeURI(name) +'&pid=1687692_15178080&cpsSign=CM_200617_1687692_15178080_73246e704c0b4a7cc45c9fbf914dc98c&duoduo_type=2" target="_blank" title="搜索不到或商品较少,请自行修改关键字,尽量简短。">拼多多搜索</a></div>';
              var tmall4 =   '<style>a.xunhuoapp{position: relative;font-size: 25px;}.xunhuoapp img.qrcode{position:absolute;z-index:99;top:35px;width:7.5rem;max-width:none;height:7.5rem;transform:scale(0);transform-origin:top right;opacity:0;border:.3125rem solid #0085ba;border-radius:.25rem;-webkit-transition:all .4s ease-in-out;-o-transition:all .4s ease-in-out;transition:all .4s ease-in-out;}.xunhuoapp:hover img.qrcode{transform:scale(1);opacity:1;}</style><div style="padding-top: 250px;"><a class="xunhuoapp" href="javascript:"><img class="xunhuoapp qrcode" src="https://tvax1.sinaimg.cn/large/63953719gy1ggbgh6ripyj208c08c749.jpg" alt="领券版app">领券版app下载</a></div>';
                 var tmall5 =   '<a class="xunhuoapp" href="https://api.qrserver.com/v1/create-qr-code/?data=https://m.tb.cn/h.4G3mvez?sm=b55619" target="_blank" title="活动互助,点击后手淘扫码">618超级星秀猫互助群</a><br/><a class="xunhuoapp" href="javascript:"><img class="xunhuoapp qrcode" src="https://api.qrserver.com/v1/create-qr-code/?data='+ encodeURIComponent(so) +''+ encodeURI(name) +'" >扫码领券</a><br/><a class="xunhuoapp" href="javascript:"><img class="xunhuoapp qrcode" src="https://api.qrserver.com/v1/create-qr-code/?data=https://tk.xunhuo.vip/m/?id=24557" >手机网页领券版(扫码后,保存书签)</a>';

            $('.tb-action').append(tmall,tmall2,tmall3,tmall4,tmall5);
            //url = 'https://tb.xunhuo.vip/api/zhekou.php?id='+ encodeURI(id) +'';
   //$.getJSON(url, function(json){
      //$('.tb-action').append('<a href="'+ json.tbk_privilege_get_response.result.data.coupon_click_url +'" target="_blank">领取优惠券</a>');
//});

        }
             //天猫超市
        else if(url == 'chaoshi.detail.tmall.com'){
            id = $('a[id=J_AddFavorite]').attr('data-aldurl')
            id = id.split("itemId=")[1]
            name = $('input[name=title]').attr('value');
            var chaoshi = '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(id) +'" title="进入后请选择浏览器打开" target="_blank">领取优惠券</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(name) +'" title="点这里可以搜索全部店铺相同名称的全部宝贝,如果想要搜索到更多商品,请修改搜索关键字,尽量简短,因为很多商家为了做优化添加了很多无用的词,造成无法搜索到更多商品。!" target="_blank">全网搜券</a></div><br />';
            var chaoshi2 = '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/jiudianjiu.aspx?id=24557" target="_blank">九块九包邮</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/item/love.aspx?type=0&sort=0&type3=13&page=1&id=24557&sid=&relationId=" title="天猫超市单品包邮宝贝" target="_blank">天猫超市热销</a></div><br /><br />';
			
			var chaoshi3 = '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://s.click.taobao.com/JL6PHnu" title="每天可领取三次" target="_blank">淘宝618红包领取</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://u.jd.com/z0YpGNs" title="每天可领取三次" target="_blank">京东618红包领取</a></div><br /><br />';

            var chaoshi4 = '<style>a.xunhuoapp{position: relative;font-size: 25px;}.xunhuoapp img.qrcode{position:absolute;z-index:99;top:35px;width:7.5rem;max-width:none;height:7.5rem;transform:scale(0);transform-origin:top right;opacity:0;border:.3125rem solid #0085ba;border-radius:.25rem;-webkit-transition:all .4s ease-in-out;-o-transition:all .4s ease-in-out;transition:all .4s ease-in-out;}.xunhuoapp:hover img.qrcode{transform:scale(1);opacity:1;}</style><div style="padding-top: 80px;"><a class="xunhuoapp" href="javascript:"><img class="xunhuoapp qrcode" src="https://tvax1.sinaimg.cn/large/63953719gy1ggbgh6ripyj208c08c749.jpg" alt="领券版app">领券版app下载</a></div>';

            $('.tb-sku').append(chaoshi,chaoshi2,chaoshi3,chaoshi4);

        }
        else if(url == 'detail.tmall.hk'){
            id = $("link[rel=canonical]").attr("href");
            id = id.split("id=")[1];
            name = $('meta[name=keywords]').attr('content');
            var tmall_hk =   '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(id) +'" title="进入后请选择浏览器打开" target="_blank">领取优惠券</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=&keyword='+ encodeURI(name) +'" title="点这里可以搜索全部店铺相同名称的全部宝贝,如果想要搜索到更多商品,请修改搜索关键字,尽量简短,因为很多商家为了做优化添加了很多无用的词,造成无法搜索到更多商品。!" target="_blank">全网搜券</a></div><br />';
		    var tmall_hk2 =   '<div class="tb-btn-buy tb-btn-sku" style="padding-top:10px;"><a href="https://s.click.taobao.com/8nWectu" target="_blank">双十二红包领取</a></div><div class="tb-btn-basket tb-btn-sku" style="padding-top:10px;"><a href="https://tk.xunhuo.vip/jingxuan.aspx?id=24557" target="_blank">每日精选</a></div>';

            $('.tb-sku').append(tmall_hk,tmall_hk2);
        }
//淘宝没有推广商品提示
             else if(url == 'tk.xunhuo.vip'){
            var tk =   '<p>抱歉这个商品没有推广,请尝试点击下方全网搜索搜寻下。</p><a href="https://tk.xunhuo.vip/m/item/list_s_super.aspx?id=24557&sid=&relationId=" target="_blank">全网搜索</a></div><br />';
			$('h2').append(tk);
        }
            //京东
             else if(url == 'item.jd.com'){
            id = $("link[rel=canonical]").attr("href");
            id = id.split(".com/")[1];
            id = id.split(".html")[0];
            name = $('meta[name=keywords]').attr('content');
            var jd =   '<a href="https://jk.xunhuo.vip/?ah=detail&id='+ encodeURI(id) +'" class="btn-special2 btn-lg" style="margin-right: 10px;" target="_blank">领取优惠券</a>';

                 var jd2 =   '<a href="http://jk.xunhuo.vip/?ah=total&kw=" class="btn-special2 btn-lg" style="margin-right: 10px;" title="搜索全网有优惠券的商品,请自行输入关键字,尽量简短。" target="_blank">京东全网搜索</a>';
                  var jd3 =   '<a href="https://tk.xunhuo.vip/m/index_super.aspx?id=24557&sid=&relationId=&relationId=" class="btn-special2 btn-lg" style="margin-right: 10px; margin-top: 10px;" title="搜索淘宝有优惠券的商品,请自行输入关键字,尽量简短。" target="_blank">淘宝搜索</a>';
                var jd4 =   '<a href="https://youhui.pinduoduo.com/search/landing?keyword=&pid=1687692_15178080&cpsSign=CM_200617_1687692_15178080_73246e704c0b4a7cc45c9fbf914dc98c&duoduo_type=2" class="btn-special2 btn-lg" style="margin-right: 10px; margin-top: 10px;" title="搜索拼多多有优惠券的商品,请复制标题或自行输入关键字,尽量简短。" target="_blank">拼多多搜索</a>';
               var jd5 =   '<a href="https://s.click.taobao.com/JL6PHnu" class="btn-special2 btn-lg" style="margin-right: 10px;" target="_blank">淘宝618超级红包</a>';
               var jd6 =   '<a href="https://u.jd.com/z0YpGNs" title="每天可领取三次" class="btn-special2 btn-lg" style="margin-top: 10px;" target="_blank">618红包领取</a>';
			                 $('div#choose-btns').append(jd,jd2,jd3,jd4,jd5,jd6);
        }

            //拼多多
             else if(url == 'youhui.pinduoduo.com'){

                 if(location.href.indexOf('?') ==-1){
        location.href=location.href+"?pid=1687692_15178080&cpsSign=CM_200617_1687692_15178080_73246e704c0b4a7cc45c9fbf914dc98c&duoduo_type=2";
    }
             id = window.location.href;
            id = id.split("goodsId=")[1];
            name = $('meta[name=keywords]').attr('content');
            var pdd =   '<style>.goods-detail-wrapper .top-wrapper {height: 100%; !important;}.goods-detail-wrapper .buy-btn {float: left; margin: 10px 0 0 10px;}</style>';

           var pdd2 =   '<a href="https://api.qrserver.com/v1/create-qr-code/?data=https://p.pinduoduo.com/mnh9jLZZ" title="红包福利专享会场,超多大额优惠券发放中,一键立抢,点击后扫码获取。" class="buy-btn" style="background-color: #171616;" target="_blank">天天拆红包</a>';
                 var pdd3 =   '<a href="https://api.qrserver.com/v1/create-qr-code/?data=https://p.pinduoduo.com/0sR9jgWK" title="【今日可领】点一下就能领15元现金,先到先得!,点击后扫码获取。" class="buy-btn" style="background-color: #171616;" target="_blank">现金刮刮卡</a>';
                 var pdd4 =   '<a href="https://youhui.pinduoduo.com/search/landing?keyword=&pid=1687692_15178080&cpsSign=CM_200617_1687692_15178080_73246e704c0b4a7cc45c9fbf914dc98c&duoduo_type=2" class="buy-btn" style="background-color: #171616;" target="_blank">拼多多全网搜索</a>';
                 var pdd5 =   '<a href="https://api.qrserver.com/v1/create-qr-code/?data=https://p.pinduoduo.com/oLn9wGsH" title="今日爆款数量有限,更有超多大额优惠券发放中,一键立抢,点击后扫码获取。" class="buy-btn" style="background-color: #171616;" target="_blank">今日爆款</a>';
                  var pdd6 =   '<a href="https://tk.xunhuo.vip/m/index_super.aspx?id=24557&sid=&relationId=" title="请复制标题自行搜索相关关键字。" class="buy-btn" style="background-color: #171616;" target="_blank">淘宝搜索</a>';
                  var pdd7 =   '<a href="https://jk.xunhuo.vip/?ah=total&kw=" title="请复制标题自行搜索相关关键字。" class="buy-btn" style="background-color: #171616;" target="_blank">京东搜索</a>';
			$('div.top-right-wrapper').append(pdd,pdd2,pdd3,pdd5,pdd4,pdd6,pdd7);

                         //券链接
          url = 'https://pdd.xunhuo.vip/api/2.php?id='+ encodeURI(id) +'';
          $.getJSON(url, function(json){
        //$('.top-right-wrapper').append('<a href="https://api.qrserver.com/v1/create-qr-code/?data='+ json.data.data +'" title="点击打开后请用拼多多app或微信扫码领取,可以使用浏览器等扫码。" class="buy-btn"  target="_blank">领取优惠券</a>');
});
                      }
    });
})();