【Wakaba】 Admin tripcodes -ATTEMPT- (16)

1 Name: Anonymous : 2008-03-05 12:29 ID:5DY64FJB [Del]

So I decided to try my luck getting Admin tripcodes to work with Wakaba.

After line 139 in futaba_style.pl add:

<if $email><if $name eq 'admname'><if $trip eq 'admtrip'><span class="admin"><a href="<var $email>"><var $name><var $trip> [Admin]</a></span></if></if></if>
<if !$email><if $name eq 'admname'><if $trip eq 'admtrip'><span class="admin"><var $name><var $trip> [Admin]</span></if></if></if>

Replace admname with Admin's name.
Replace admtrip with Admin's output tripcode including the trip characters ('!' by default).
You can remove <var $trip> from both lines and simply have it so that it shows admname [Admin]
For multiple admins, simply repeat the code above onto the very next line.

Go into your \css\ folder and edit the css styles.
Add:

.admin{

}

... with your own set of formatting between the brackets for each available theme.

The cheap mod does it's job... sort of. I'm not familiar with Perl and neither am I any good at coding and structure, so following that - theres a problem in the fact that the name and trip show up twice on the boards front page and reply mode as such:

 name!!trip [Admin] name!!trip 08/03/06(Thu)06:00  No.7

I'm not too sure how to go about making it ignore the code that comes after it:

<if $email><span class="postername"><a href="<var $email>"><var $name></a></span><if $trip><span class="postertrip"><a href="<var $email>"><var $trip></a></span></if></if>
<if !$email><span class="postername"><var $name></span><if $trip><span class="postertrip"><var $trip></span></if></if>

If anyone knows how to and would like to help, please, fire away.

This code works perfectly if you just want to have an admin tag of some sort. Simply remove both the <var $name><var $trip> from the 2 lines you added.

2 Name: Anonymous : 2008-03-06 17:54 ID:zhHgQIhP [Del]

alternately, use kareha.

3 Name: Anonymous : 2008-03-06 19:34 ID:Heaven [Del]

or put important announcements in rules.html or something like that and don't do faggotry like having "admin posts" mixed in with normal posts.

4 Name: Anonymous : 2008-03-07 01:33 ID:Heaven [Del]

>>3
Sometimes people just need a little nudge to prove that the admins actually watch the board, if they're bending the rules, testing the waters, or whatever else you might want to call it.

5 Name: Anonymous : 2008-03-07 13:52 ID:Heaven [Del]

>>4
post deletion works just fine for that.
or if they're just bending the rules, not breaking them, permasage.

6 Name: Anonymous : 2008-03-07 23:15 ID:Heaven [Del]

>>5
Yes this is for wakaba which also doesn't have that feature, and on which a permasage would likely go unnoticed anyway.

7 Name: Anonymous : 2008-03-18 09:15 ID:VAZmL9Ky [Del]

It's not hard to add sticky, permasage and close options to Wakaba, if anything it's harder to add new features to Kareha. Capcodes are useful for having a mod post to make warnings, etc in threads (or just wanting to be faggy and posting with colours). Should be easy to add as well.

8 Name: Anonymous : 2008-03-18 17:49 ID:Heaven [Del]

>>7
I've found both scripts to be quite flexible in their own ways. It does largely depend on what sorts of things you're trying to do with them, though.

9 Post deleted by moderator.

10 Post deleted by moderator.

11 Post deleted by moderator.

12 Name: Anonymous : 2011-08-31 07:17 ID:5n/a0aGh [Del]

Hey, I am having trouble getting this to work. I am supposed to put it after:

<label><input type="checkbox" name="delete" value="<var $num>" />

Right? I was thinking that if a new version of wakaba might have been released since 2008, line 139 might have changed.

Would appreciate any help, thanks! :)

13 Name: Anonymous : 2011-10-15 02:31 ID:eH3fLyNv [Del]

Any chance you could update this to work with data from a database?

E.g. wakaba_staff

num - 1
name - Admin
tripcode - !4uce84

And loop through each row until it finds a match? It would be great for multiple admins, and no need to make file edits each time. :)

14 Name: Anonymous : 2011-11-07 11:29 ID:Heaven [Del]

I've never understood what's so hard about adding cap codes... Its just a few lines in wakaba.pl, and nothing more. Are you guys trying to get it working outside of the manager post section?

15 Post deleted by moderator.

16 Post deleted by moderator.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification: