Guild icon
Direct Messages
ACXYZ
5:49 AM
join
Avatar
is there a way koko can detect if its on index?
Avatar
like a thread?
3:09 AM
yeah it can
Avatar
i already figured it out
3:09 AM
using resto
3:10 AM
i am pretty good at koko
Avatar
resto=0, right
Avatar
nowadays, i developed my own thing
3:10 AM
ive added a few new features to koko
Avatar
Yahoo! ^_^
3:19 AM
does koko know how to tell thread order on index?
3:19 AM
as in, most recently bumped thread is 1
3:19 AM
second is 2
3:19 AM
etc
Avatar
bumped order?
3:19 AM
yes it did
3:19 AM
Yes, bumped order
3:20 AM
bump works
3:20 AM
yeah
3:20 AM
but is there a way to print the threads bump order
Avatar
Avatar
ACXYZ
Click to see attachment 🖼️
post no.12 is at the top so its #1
3:20 AM
post no.1 is second, so #2
3:20 AM
etc
Avatar
LIKE THAT???
3:20 AM
OH OK
Avatar
cant you just do the same thing you did avec textboards?
3:21 AM
the false post order
Avatar
right, but thats for posts in a thread
3:21 AM
im trying to count the threads on the index
Avatar
something something
3:22 AM
arrangethread()
3:22 AM
take the i from when its counting
Avatar
use that as your number 1
3:23 AM
Yay!! (^_^)/
Avatar
whats the best way to calculate total number of posts in a thread?
Avatar
total?
3:33 AM
ok
3:33 AM
one sec
3:33 AM
Ok
3:33 AM
you get the op thread (say 123)
3:33 AM
then get the posts with a resto of 123
Avatar
sounds taxxing on the database..
Avatar
since its index'd, shouldnt be
Avatar
unless you're using sqlite
3:35 AM
3:35 AM
using a command like this, you'd get your result
3:47 AM
just use postCount($resno)
3:47 AM
: D
Avatar
that gives you exactly what you want
3:47 AM
use it like
3:48 AM
$PIO->postCount($resto)
3:49 AM
that just prints 1219 over and over.. https://up.kuz.netmode.ru/src/2023-02-05-01504.png
Avatar
did you double check?
Avatar
I added $TPC to the templates (And modified koko so it would pass it through the template properly)
3:50 AM
then added $TPC = $PIO->postCount($resto);
3:50 AM
to make my thread counter next to title work on koko textboards
Avatar
is this in a forloop?
3:51 AM
No
Avatar
do that
3:52 AM
otherwise it'll just keep saying the same thing
Avatar
where did u place your $TPC thing
Avatar
like 395 (below the threadnav things)
3:54 AM
3:54 AM
just kind of randomly
Avatar
you did something like
3:55 AM
'{$TPC}'=>$TPC, (edited)
Avatar
the OP part
3:59 AM
33
Avatar
is 33 the number of replies to that thread?
Avatar
how did u do it
Avatar
Avatar
j
how did u do it
4:01 AM
like that
Avatar
thanks bobman ^_^
4:02 AM
it worked
Avatar
Yahoo! ^_^
Avatar
Your latest "swf" update breaks .webm and .mp4 thumbnails
Avatar
It just doesnt work?
Avatar
It makes all thumbnails become swf ones
7:47 PM
even non .swf files
Avatar
Did you try that out?
Avatar
Try what out?
Avatar
swf update* (edited)
Avatar
.swf files work
7:48 PM
but.. all of them do
7:48 PM
as in mp4's and webm's get a swf thumbnail too
Avatar
could you send the img.js plz (edited)
Avatar
I dont use the kokonotsuba repo
7:49 PM
i use my own
7:49 PM
im just reporting from kaguya
7:49 PM
you should talk to him about it
Avatar
its not emergency
7:53 PM
Avatar
is that from kaguya?
Avatar
No that was my own test just now
7:55 PM
Then plz send your img.js
7:58 PM
swfext: isnt there
7:58 PM
This should work
2:44 AM
Ive been trying to modify kokotxt so that the postform displays inside the thread (on board view)
2:44 AM
but it never werkd
2:44 AM
any tips?
Avatar
Avatar
j
Ive been trying to modify kokotxt so that the postform displays inside the thread (on board view)
for every single thread? (main view)
4:31 AM
(works best in kokotxt mode, so switch your templates to kokotxt if you havent and want to test this)
Avatar
Postforms only gonna work for making a new thread on index (edited)
7:34 PM
Sorry for the delay
Avatar
Not problem
Avatar
Avatar
ACXYZ
Postforms only gonna work for making a new thread on index (edited)
okay ;_;
12:16 AM
thoughts on this mobile design for koko?
12:18 AM
Works nice!
12:18 AM
But it does scroll to the right a bit when it gets wide
12:25 AM
do you use mod_archiver?
11:05 PM
https://github.com/vichan-devel/vichan-API/ $apiUrl = 'http://vichan.example/'; $boardName = 'test'; // Loop through all the pages and count the replies made in the last hour $count = 0; $now = time(); for ($i = 0; $i <= 21; $i++) { $jsonIndex = file_get_contents($apiUrl . $boardName . '/' . $i . '.json'); $index = json_decode($jsonIndex, true); $threads = $index['threads']; foreach ($threads as $thread) { $threadNumber = $thread['no']; $threadApiUrl = $apiUrl . $boardName . 'res/' . $threadNumber . '.json'; $threadJson = file_get_contents($threadApiUrl); $threadData = json_decode($threadJson, true); $replies = $threadData['posts']; foreach ($replies as $reply) { if ($reply['time'] > $now - 3600) { $count++; } } } } // Output the count echo $count . ' replies made in the last hour on /' . $boardName . '/';
11:05 PM
do you see a problem in my code for checking a vichan boards pph?
Avatar
did you try it out?
Avatar
yeah it just says 0 postd
Avatar
same code?
Avatar
instead of looking through each thread (edited)
12:07 AM
check the thread index http://localhost/vichan/b/threads.json (edited)
12:07 AM
for its recently changed posts
12:32 AM
m
12:32 AM
?
Avatar
instead of checking each post
1:17 AM
wait
5:21 AM
i am still wait
Avatar
sorry for the wait
5:27 AM
just get a list of threads in a board
Avatar
i tried alot
5:27 AM
could u see if you could modify it
Avatar
http: //yahooman/b/catalog.js (edited)
12:43 AM
i couldnt get it working
7:55 AM
Fredrick Brennan decided to give me maintainership of vichan, so i am now its new owner so to speak
7:55 AM
Avatar
hi kuz!
7:56 AM
that sounds so cool! :D
7:57 AM
do you want to hop on irc and meet the guys?
7:57 AM
Fred is in there too
Avatar
join #vichan-dev
Avatar
kolymairc?
Exported 181 message(s)
Timezone: UTC+0