Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Jul 28, 2020 5:11:03 GMT
i made a [staff ] [ /staff] tag (dont use spaces in the tags). anything inside it will only be viewable by staff, if ur not a staff member, it says "Only staff may view this". put funny staff only msgs now.
Example: [staff]ops get no rights[/staff]
|
|
|
Post by DragonSlayer2189 on Jul 28, 2020 5:44:57 GMT
it didnt work, i can see the "only staff may view this"
[staff]lol fuck fionn[/staff]
oh nvm now i see how it works
actually it turns out that if you reload the page you can see it for a bit before it gets hidden "ops get no rights"
|
|
Zaid
Veteran Member
When it is said to them, "Do not cause corruption on the earth," they say, "We are but reformers."
Posts: 3,007
|
Post by Zaid on Jul 28, 2020 5:50:41 GMT
it didnt work, i can see the "only staff may view this" [staff]lol fuck fionn[/staff] oh nvm now i see how it works actually it turns out that if you reload the page you can see it for a bit before it gets hidden "ops get no rights" i can also see it if i quote it lol
|
|
Video
Forum Admin
An op's rights activist
Posts: 5,585
| Likes: 5,893
IGN: VideoGameSmash12, videogamesm12
Old IGN: https://namemc.com/profile/VideoGameSmash12.2, https://namemc.com/profile/videogamesm12.1
Discord: Video#9801
Birthdate (MM/DD): 07/16
Timezone: UTC-07:00
Member is Staff. Need immediate assistance? Send a PM
|
Post by Video on Jul 28, 2020 5:54:03 GMT
|
|
speed
Full Member
Posts: 158
| Likes: 465
|
Post by speed on Jul 28, 2020 5:55:35 GMT
|
|
zeseryu
Veteran Member
Admin Officer
ops rights activist
Posts: 1,181
|
Post by zeseryu on Jul 28, 2020 6:01:42 GMT
Kelly Kant Kode
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Jul 28, 2020 6:03:11 GMT
u can also see it if u disable js. this thing should be done server side when the msg is parsed, but since I don't host the forums I can't do it. fuck proboards
|
|
nick
Veteran Member
Posts: 766
|
Post by nick on Jul 28, 2020 6:14:41 GMT
So, why did you make this little plugin? And does it work without an issue beside disabling js.
|
|
Video
Forum Admin
An op's rights activist
Posts: 5,585
| Likes: 5,893
IGN: VideoGameSmash12, videogamesm12
Old IGN: https://namemc.com/profile/VideoGameSmash12.2, https://namemc.com/profile/videogamesm12.1
Discord: Video#9801
Birthdate (MM/DD): 07/16
Timezone: UTC-07:00
Member is Staff. Need immediate assistance? Send a PM
|
Post by Video on Jul 28, 2020 6:37:45 GMT
Here's the source code of the plugin:
function parseStaffTags() { var path = location.pathname; if (path.startsWith("/thread") || path.startsWith("/posts")) { var posts = document.getElementsByClassName("message"); console.log(posts.length); for (var i = 0; i < posts.length; i++) { var post = posts[i]; var reg = /\[staff\](.*?)\[\/staff\]/; if (post.innerHTML != null) { var replaceWith = "$1"; if (!yootil.user.is_staff()) { replaceWith = "Only staff may view this"; } post.innerHTML = post.innerHTML.replace(reg, replaceWith); } } } } window.addEventListener("load", parseStaffTags);
|
|
StevenNL2000
Forum Admin
Posts: 6,415
| Likes: 6,936
IGN: StevenNL2000
Timezone: UTC+01:00
Member is Staff. Need immediate assistance? Send a PM
|
Post by StevenNL2000 on Jul 28, 2020 9:44:28 GMT
|
|
|
Post by DragonSlayer2189 on Jul 28, 2020 10:27:17 GMT
u can also see it if u disable js. this thing should be done server side when the msg is parsed, but since I don't host the forums I can't do it. fuck proboards doesn't finest host it, cant u just ask him, or am i wrong
|
|
fionn
Club 4000 Member
Admin Officer
elmon sucks
Posts: 6,157
| Likes: 4,775
|
Post by fionn on Jul 28, 2020 10:28:08 GMT
u can also see it if u disable js. this thing should be done server side when the msg is parsed, but since I don't host the forums I can't do it. fuck proboards doesn't finest host it, cant u just ask him, or am i wrong finest doesn't host it, proboards does finest simply created the forums
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Jul 28, 2020 18:46:19 GMT
So, why did you make this little plugin? And does it work without an issue beside disabling js. because im without my computer till wednesway when I move all my shit. i was really bored and wanted to make a concept of it, if I could do it server side (ill look into the thing steven said) then I could use it to hide user ips on ban appeals n shit
|
|