The Legendary Next Update (365)

10 Name: Anonymous 2005-10-12 22:19 ID:UAOHJNRy [Del]

>>9
That's an option, you pick which one you want.

243 Name:   2005-10-22 10:54 ID:Heaven [Del]

If you want to have a look at what the code actually does to dig out flaws, here is the current version:

sub sanitize_html($%)
{
my ($html,%tags)=@_;
my (@stack,$clean);
my $entity_re=qr/&(?!\#[0-9]+;|\#x[0-9a-fA-F]+;|amp;)/;

while($html=~/(?:([^<]+)|<([^<>]*)>?)/g)
{
my ($text,$tag)=($1,$2);

if($text)
{
$text=~s/$entity_re/&amp;/g;
$text=~s/>/&gt;/g;
$clean.=$text;
}
else
{
if($tag=~m!^\s*(/?)\s*([a-z0-9_:\-\.]+)(?:\s+(.*?)|)\s*(/?)\s*$!si)
{
my ($closing,$name,$args,$implicit)=($1,lc($2),$3,$4);

if($tags{$name})
{
if($closing)
{
if(grep { $_ eq $name } @stack)
{
my $entry;

do {
$entry=pop @stack;
$clean.="</$entry>";
} until $entry eq $name;
}
}
else
{
my %args;

$args=~s/\s/ /sg;

while($args=~/([a-z0-9_:\-\.]+)(?:\s*=\s*(?:'([^']*?)'|"([^"]*?)"|['"]?([^'" ]*))|)/gi)
{
my ($arg,$value)=(lc($1),defined($2)?$2:defined($3)?$3:$4);
$value=$arg unless defined($value);

my $type=$tags{$name}{args}{$arg};

if($type)
{
my $passes=1;

if($type=~/url/i) { $passes=0 unless $value=~/(?:^$protocol_re:|^[^:]+$)/ }
if($type=~/number/i) { $passes=0 unless $value=~/^[0-9]+$/ }

if($passes)
{
$value=~s/$entity_re/&amp;/g;

if($value=~/"/) { $value="'$value'" }
else { $value="\"$value\"" }

$args{$arg}=$value;
}
}
}

my $cleanargs=join " ",map { "$_=$args{$_}" } keys %args;

$implicit="/" if($tags{$name}{empty});

push @stack,$name unless $implicit;

$clean.="<$name";
$clean.=" $cleanargs" if $cleanargs;
$clean.=" $implicit" if $implicit;
$clean.=">";
}
}
}
}
}

my $entry;
while($entry=pop @stack) { $clean.="</$entry>" }

return $clean;
}

294 Name: !WAHa.06x36 : 2005-10-23 20:38 ID:Heaven [Del]

> I don't see a big fat ugly WakabaMark FAQ next to the post form either.

You don't see the link to the WakabaMark page either?

> I am just guessing here, but I am pretty sure most people will only change their settings in very rare cases.

I just added the Text Art mode so that people could post AA on any board and have it work right, but the only way for that to work is if you can quickly change modes between posts.

Look, it's getting just a tiny bit annoying with the complaining. I've been putting a huge amount of effort into making this work well both for those who want markup and those who don't. If you don't like it, you turn it off and don't need to bother with it again. There's just a tiny little link there to let people do this. Is this really a such a huge bother to deal with? It's *two words*.

129 Name: Anonymous 2005-10-18 17:18 ID:Heaven [Del]

Damn, I was about to plug >>96 when I saw you uploaded the new version. Thanks for listening WAHa, you're awesome. :D

(Does this work like rules.html in mode_image? Is the board title inserted automatically in templates.pl or is it part of that separate html file?)

Already a few nitpicks though: (1) index.html#menu and index.html#1 links should be automatically inserted to the right of the board title (or below if you're looking at it without CSS), and (2) the "Create new thread" title isn't really necessary, since the widget button already explains its function (like with the reply box).

Unrelated: in 2ch thread lists, position numbers are followed by colons, not periods.

129 Name: Anonymous 2005-10-18 17:18 ID:Heaven [Del]

Damn, I was about to plug >>96 when I saw you uploaded the new version. Thanks for listening WAHa, you're awesome. :D

(Does this work like rules.html in mode_image? Is the board title inserted automatically in templates.pl or is it part of that separate html file?)

Already a few nitpicks though: (1) index.html#menu and index.html#1 links should be automatically inserted to the right of the board title (or below if you're looking at it without CSS), and (2) the "Create new thread" title isn't really necessary, since the widget button already explains its function (like with the reply box).

Unrelated: in 2ch thread lists, position numbers are followed by colons, not periods.

227 Name: Anonymous 2005-10-21 17:21 ID:Heaven [Del]

>>226
(´・ω・`)

256 Name: Anonymous 2005-10-22 13:23 ID:Heaven [Del]

>>255
By replacing it with AN EVEN DUMBER PUN!

134 Name: Anonymous 2005-10-18 17:37 ID:EoLJTz7L [Del]

How about a function to replace an inappropriate image with a standard image? (aka HelloKitty.gif)

157 Name:   2005-10-19 14:11 ID:gBva8ggI [Del]

>>153

http://en.wikipedia.org/wiki/Public_Domain

It means anyone can do whatever they want with it. They can't claim copyright, though, since they didn't create it in the first place. They can modify it an claim copyright on their modifications, at least as long as they're significant enough, but that doesn't affect existing works in the public domain.

> This is kinda what I had pushed for earlier in >>52. I think that separating the sage (aka, "don't bump"), fusianasan (aka, "show IP"), and ID:Heaven (aka, "no ID") functions from any particular post elements in the main scripts would be ideal for implementing Kareha in systems where inputting a certain string to trigger these functions is not intuitive (ie, every board outside of the 2ch/Futaba family). These trigger strings (S_DONTBUMP, S_SHOWIP, S_NOID) and their assignment to a certain form field input could be instead implemented individually in each template.

There's no obvious way to do this, since there has to be code that specifically checks a field and takes certain actions long before the template comes into play. It'd take some sort of plugin system to implement it, and I don't think that's quite called for.

Also >>154 is Kami.

176 Name: Anonymous 2005-10-20 02:32 ID:Heaven [Del]

PS: I just tested fusianasan + tripcode on 2ch, it works fine.

291 Name: Anonymous : 2005-10-23 19:54 ID:Heaven [Del]

No "2ch mode" link in the footer? I think Hiroyuki deserves some credit.

328 Name: !WAHa.06x36 : 2005-10-26 19:34 ID:SjmelPTB [Del]

> What about a(n) (optional) preview page?

I've been considering that, but it's a goddamn pain to implement. It'd be pretty useful, though. Also, it could include the spell checker someone requested way back at the beginning of time.

76 Name: Anonymous 2005-10-17 08:46 ID:Heaven [Del]

>>74
The comma range separator is useful for anchoring a certain post range to the first post (ie, "1,-100"), but that's all I can really think of. Still, I appreciate such a degree of flexibility.

140 Name: Anonymous 2005-10-18 20:03 ID:Heaven [Del]

>>137
I also noticed that you removed the CSS selector in individual thread views. Personally, it seems both the Admin options and Style selector are a bit of a hindrance to the overall layout. Don't get me wrong -- I think the drop-in Style capability is fantastic-- but it just doesn't seem to play nice with the current 2ch page design.

The thing is, don't most or all major browsers these days allow users to change CSS styles from within the application itself? I know Firefox does, at least. Maybe the selector isn't really necessary.

259 Name: coda 2005-10-22 15:01 ID:1jzeBBcT [Del]

the text

c < d

causes a <d> tag to be opened, which is not on the list, and therefore all the text until the next tag will be deleted. a better behavior in this case would be to just convert that < to &lt;. you even ought to do this for

a < b

too, despite the fact that b is a valid tag, because who the hell leaves the closing angle bracket out of their HTML tag?

creating the correct regexes for this is an exercise left to the reader.

97 Name: Anonymous 2005-10-17 14:14 ID:Heaven [Del]

>>96
forgot to mention that maybe a parameter could be included in config.pl to define an XHTML file for the disclaimer/rules block. It could be used both in 2ch and Futaba (right under the posting area) modes.

137 Name:   2005-10-18 19:23 ID:gBva8ggI [Del]

Removed it when redesigning the page head, haven't figured out quite what to do about it yet. It needs to be changed, but to what, I'm not yet sure.

337 Name: !WAHa.06x36 : 2005-10-27 04:53 ID:Heaven [Del]

I don't see what's so bad about >>330. The alternative is to force the table to be full width, which will make it uglier (because in HTML all columns will become wider, including the skinniest ones), and harder to read.

> No need for a database, just a text file. You're right about storing IPs, though, but then how can you implement a banning system? Do you use an encrypted IP like the algorithm to generate ID codes?

Banning is done through Apache, which really makes more sense than doing it in the script. I don't want to re-invent the wheel for that.

> I mean that (for example) if I wanted to replace the permasaging function under the MAX_POSTS condition (permasage after X posts) with the thread-closing function (close after X posts), all it would require is a simple replacement of the proper function references in post_stuff(), correct?

No, they're done at different different places, because they are essentially different functions. The permasage behaviour doesn't actually permasage a thread, it only refrains from bumping it. There's no permsage flag added to the thread. The closing, on the other hand, does add a flag to the thread.

> Making "More options..." an option in the configs.
> Seems sensible, when you already have the ability to turn off WakabaMark as a board admin.

No. And I actually removed the DISABLE_WAKABAMARK option since it's no longer really needed. The replacement will be an option to select the default markup for a board, which makes much more sense overall.

29 Name: Anonymous 2005-10-14 00:40 ID:Heaven [Del]

Funky, works... I am pretty sure the error has something to do with the characters preceeding the "¦" in the unprocessed tripcode. It begins with a "`"

250 Name: Anonymous 2005-10-22 12:58 ID:tsGarR30 [Del]

>>249 Then the default should be no markup.

233 Name: Anonymous 2005-10-21 22:16 ID:Heaven [Del]

>>232
Nothing! But since mode_image's footer.html includes a link to Futaba called "Futaba mode," I think mode_message should have the same.

168 Name:   2005-10-19 19:00 ID:gBva8ggI [Del]

> (albeit edge cases)

Which is the crux of the matter - it mostly doesn't matter to the vast majority of users.

> You still end up with no way to link the fusianasan post with the name/trip one without IDs enabled (unless the ID method is known and no secret data is used).

You can use fusianasan with a tripcode, at least on Kareha. I suspect you can on 0ch too, but I haven't checked.

180 Name: Anonymous 2005-10-20 06:32 ID:Heaven [Del]

>>178
There will always be pranksters around. This is probably a good example on what matters to trust tripcoders more than anonymous contributors.

Trivia: Here is a list of 2ch kopipe to fool people into using fusianasan:
http://ansitu.xrea.jp/guidance/?fusianasan

74 Name: Anonymous 2005-10-17 08:29 ID:Heaven [Del]

> To more closely resemble the 2ch look, how about prefixing thread title headers in the main board page with a 【position:postcount】thingie?

2channel does not do this either by default. It can make browsing a bit more convenient (and I suspect dedicated 2channel browsers to insert & read these in some kind of standardized way) but I don't think that's reason enough to impose it on users by default.

> Of course, this could get screwy if you're using reverse order and out-of-order posts in the URL, so I dunno how well it could be implemented.

Personally, I find the reverse order listing, as well as the random order listing, to be a bit silly & useless. The only useful bonus feature here seems to be the comma range seperator, but it seems even in that case there is not much benefit to it (saves 1-3 links in the average case that it is needed, which is rare to begin with).

> The "First 100" link should also be removed from the bottom of individual thread pages, and there should be a link to to thread-list included below the reply box of each previewed thread on the front page.

signed

> In order for the CSS selector not to take over the entire header, how about turning it into a drop-down menu?

This was proposed before (long time ago) and it is hereby also signed.

> and would something like this work (given that all boards share the same root directory)?

That's a tricky bit and I think it was decided against because it would be too much work to properly maintain such a function at the time when 4chan implemented it.

275 Name: !WAHa.06x36 : 2005-10-23 16:53 ID:Heaven [Del]

> The File field is almost never there.

...especially not when I've added a bug that makes it disappear. Where the hell did it go?

316 Name: !WAHa.06x36 : 2005-10-25 05:01 ID:Heaven [Del]

Nothing specific, just protecting against any possible future ones.

351 Name: dmpk2k!hinhT6kz2E : 2005-10-28 04:55 ID:Heaven [Del]

I think you're a bit nutty, >>350...

141 Name: dmpk2k!hinhT6kz2E 2005-10-18 20:42 ID:Heaven [Del]

> Also, I couldn't be arsed to fix Amber, since it was just a joke in the first place.

Booo!

> who here finds enough use in the auto-expanding comment box to justify the annoyances when you click in or out of it?

I love that feature. Please don't remove it!

> I think the drop-in Style capability is fantastic-- but it just doesn't seem to play nice with the current 2ch page design.

plz 2 be keeping that feature too

12 Name: test 2005-10-13 02:11 ID:Heaven [Del]

>>10
Exactly, but considering a lot of people can't make heads from tails in config.pl, how about a saner default?

>>11
That's true, but if least-popular threads are set to be deleted, instead of oldest-first, you don't have to guess.

218 Name: Anonymous 2005-10-21 15:22 ID:Heaven [Del]

>>209

>> More information on the all threads page, date of the last post? file size?

Well, I had already proposed the filesize indicator in >>208, but optimally I would actually prefer that subback resemble the one in 0ch (ie, same as the main page thread list, but without CSS).

And single-post links don't include the thread's first post anyway, so there's no need for >>n. Quoting an entire post is not wise either.

>>211

>Isn't this essentially the same as saying "Please don't talk so much?"

In a sense, yes. Just like the postcount limit could be interpreted as "Please don't talk so long".

>what

main page -- 161 Name:◆WAHa.06x36:2005/10/21(Fri) 14:44 ID:Heaven
subpage -- 4 :◆WAHa.06x36:2005/10/21 14:44 ID:Heaven

Question: does Kareha have a 1001th post message like "Name: 1001:Over 1000 Thread" for when a thread exceeds its postcount limit?

This thread has been closed. You cannot post in this thread any longer.