เชื่อว่าต้องมีบ้างล่ะ ที่เวลาอ่านกระทู้แล้วเจอความเห็นจากคนนี้อีกละ ไม่ชอบเลย ไม่อยากเห็นความเห็นจากยูสเซอร์นี้เลย ทำได้ไหม?
มีคนทำสคริปมาให้ใช้กันนานแล้ว (เพิ่งรู้เหมือนกัน) ลองทำตามแล้วได้ผล
หลักการคือ install extension ใน chrome หรือ firefox แล้วเอาสคริปโค้ดจาก จขกท ใน link ข้างล่างไปวาง แล้วก็ทำตามวิธีที่อธิบายในกระทู้นั้น
เท่านี้ความเห็นจาก user ที่คุณไม่ต้องการก็จะหายวับไปทันที

(สามารถ enable/disable หรือ แก้ไขชื่อที่บล๊อก ได้ตามต้องการ ถ้าอยากเห็นเหมือนเดิม)
วิธีตามนี้
https://ppantip.com/topic/33538300/
ส่วนโค้ด เมื่อเปิด create new user script ขึ้นมา ก็เอาโค้ดข้างล่างนี้วางได้เลยครับ แทนโค้ดเดิมทั้งหมด (สำหรับ chrome)
[Spoil] คลิกเพื่อดูข้อความที่ซ่อนไว้
// ==UserScript==
// @name Pantip Block User
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @include https://ppantip.com/*
// @grant none
// ==/UserScript==
/*Pantip block and ban word script by ฮีโร่ดอย@ppantip.com (HeroDoi@ppantip.com)
------------------------------------------------------------------------------
Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0)
http://creativecommons.org/licenses/by-nc-nd/4.0/
------------------------------------------------------------------------------
=====================
You are free to:
=====================
Share — copy and redistribute the material in any medium or format
The licensor cannot revoke these freedoms as long as you follow the license terms.
=====================
Under the following terms:
=====================
Attribution — You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
NonCommercial — You may not use the material for commercial purposes.
NoDerivatives — If you remix, transform, or build upon the material, you may not distribute the modified material.
No additional restrictions — You may not apply legal terms or technological measures that legally restrict others from doing anything the license permits.
*/
var BanWordList = [];
var BlockList = [];
//=========================
// API
//=========================
function LoadList() {
var BlockIn = localStorage.getItem("BlockData");
var BanIn = localStorage.getItem("BanData");
if (BlockIn) BlockList = BlockIn.split("\n");
if(BanIn) BanWordList = BanIn.split("\n");
return [BlockIn, BanIn];
}
function SaveList(BlockIn, BanIn) {
localStorage.setItem("BlockData", BlockIn);
localStorage.setItem("BanData", BanIn);
BlockList = BlockIn.split("\n");
BanWordList = BanIn.split("\n");
}
//=========================
// GUI Setup
//=========================
var HStyle = (function () {/*
.Body { position:fixed; width:50%; height:480px; z-index: 9999 !important;
top: 60px; left:25%; padding: 5px;
background-color: #3C3963; color: #FFCD05;
font-size: 1.71em;
font-weight: 400;
line-height: 120%; text-align:center;
border: 1px solid #8E8BA7;
}
.Body a {color: #FFCD05;}
.Body button, .Body hr { width:91%; }
.Body div>div, .Body textarea { width:45%; }
.Body div>div {display:inline-block; text-align:center;}
.Body textarea {height:240px; font-size:24px; background-color:#0E5C6A; border:1px solid #4793A1; color:#fff;}
.Body button {font-size:24px; background: #33315D;
border: 1px solid #6C6A8D;
border-top: 1px solid #8D89D8;
color: #E9E5F6;
font-style: normal;
font-weight: 700;
padding: 3px 8px 4px;
text-shadow: 0px 1px 1px #3E3C7F;
cursor:pointer;
}
.Body button:hover { background:#639230; }
*/}).toString().match(/[^]*\/\*([^]*)\*\/\}$/)[1];
var HeroStyle = document.createElement("STYLE");
HeroStyle.innerHTML = HStyle;
document.body.appendChild(HeroStyle);
var HBody = (function () {/*
<div><div>Block List</div><div>Ban word List</div></div>
<textarea id="BlockInput"></textarea>
<textarea id="BanInput"></textarea>
<br/><br/>
<button id="SaveInput">Save</button>
<hr />
<div><a href="http://ppantip.com/profile/182884">By ฮีโร่ดอย@ppantip.com</a></div>
<hr />
<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/4.0/">
<img alt="Creative Commons License" style="border-width:0"
src="https://i.creativecommons.org/l/by-nc-nd/4.0/88x31.png" width="115;" /></a>
*/}).toString().match(/[^]*\/\*([^]*)\*\/\}$/)[1];
var HeroFrame = document.createElement("DIV");
HeroFrame.id = "HeroDoi";
HeroFrame.className = "Body";
HeroFrame.style.cssText = "opacity:0; display:none;";
HeroFrame.innerHTML = HBody;
document.body.appendChild(HeroFrame);
SaveInput.addEventListener("click", function () {
SaveList(BlockInput.value, BanInput.value);
HeroDoi.style.cssText = "opacity:0; display:none;";
});
var DataIn = LoadList();
BlockInput.value = DataIn[0];
BanInput.value = DataIn[1];
//=========================
// GUI
//=========================
var Menu = document.querySelectorAll(".pt-dropdown-menu");
if (Menu.length > 0) {
for (var i = 0; i < Menu.length; i++) {
var BanButton = document.createElement("LI");
BanButton.innerHTML = '<a><div class="pt-lists-item"><span class="pt-lists-item__graphic pantip-icons pt-ic-setting"></span><span class="pt-lists-item__text"></span>Block/Ban list</div></a>';
BanButton.addEventListener("click", function () {
HeroDoi.style.cssText = "opacity:1; display:block;";
});
Menu[i].appendChild(BanButton);
}
}
//=========================
// Core
//=========================
function CheckList(Name) {
for (var i = 0; i < BlockList.length; i++) if (BlockList[i] == Name) return true;
return false;
}
function CheckWord(Word){
for (var i = 0; i < BanWordList.length; i++) if (Word.indexOf(BanWordList[i]) >= 0) return true;
return false;
}
setInterval(
function () {
var GS = document.getElementById("comments-jsrender");
LoadList();
var GSI, GSN, GSW, i;
if (GS) {
//Comment clear
GS = document.querySelectorAll(".section-comment");
for (i = 0; i < GS.length; i++) {
GSI = GS[i];
GSN = GSI.querySelector(".display-post-name");
if (GSN) if (CheckList(GSN.innerHTML)) GSI.parentElement.removeChild(GSI);
GSW = GSI.querySelector("display-post-story");
if (GSW) if (CheckWord(GSW.innerHTML)) GSI.parentElement.removeChild(GSI);
}
} else {
//Topic clear
GS = document.querySelectorAll(".post-item");
for (i = 0; i < GS.length; i++) {
GSI = GS[i];
GSN = GSI.querySelector(".by-name");
if (GSN) if (CheckList(GSN.innerHTML)) GSI.parentElement.removeChild(GSI);
GSW = GSI.querySelector(".post-item-title>a");
if (GSW) if (CheckWord(GSW.innerHTML)) GSI.parentElement.removeChild(GSI);
}
}
}, 1000);
ใส่โค้ดแล้ว เลือก File > Save
แล้วรีเฟรช pantip
แล้วกด บัญชีผู้ใช้ จะเห็นเมนูเพิ่มขึ้นมาด้านล่าง กดเข้าไปแล้วใส่รายชื่อได้เลย
เผื่อมีประโยชน์ สำหรับคนเบื่อดราม่า ด้วยวิธีบล๊อกยูสเซอร์
มีคนทำสคริปมาให้ใช้กันนานแล้ว (เพิ่งรู้เหมือนกัน) ลองทำตามแล้วได้ผล
หลักการคือ install extension ใน chrome หรือ firefox แล้วเอาสคริปโค้ดจาก จขกท ใน link ข้างล่างไปวาง แล้วก็ทำตามวิธีที่อธิบายในกระทู้นั้น
เท่านี้ความเห็นจาก user ที่คุณไม่ต้องการก็จะหายวับไปทันที
(สามารถ enable/disable หรือ แก้ไขชื่อที่บล๊อก ได้ตามต้องการ ถ้าอยากเห็นเหมือนเดิม)
วิธีตามนี้
https://ppantip.com/topic/33538300/
ส่วนโค้ด เมื่อเปิด create new user script ขึ้นมา ก็เอาโค้ดข้างล่างนี้วางได้เลยครับ แทนโค้ดเดิมทั้งหมด (สำหรับ chrome)
[Spoil] คลิกเพื่อดูข้อความที่ซ่อนไว้
ใส่โค้ดแล้ว เลือก File > Save
แล้วรีเฟรช pantip
แล้วกด บัญชีผู้ใช้ จะเห็นเมนูเพิ่มขึ้นมาด้านล่าง กดเข้าไปแล้วใส่รายชื่อได้เลย