- Posts: 10
- Thank you received: 1
Kunena 7.0.11 & Kunena 6.4.16 – Security Updates Released and K7.1 in RC1 2
The Kunena team has announce the arrival of three simultaneous security release : K6.4.16, K7.0.11 and K7.1 RC2. Just a reminder K6.4.16 receives only securities fixes untill end of 2026, so it's advised for users to upgrade to K7.0.11. K7.0.11 is the last release of the K7.0 because it's replaced by K7.1 branch with the stable release in the corner. The translations for K7.1 on crowdin.com/project/kunena-forum-7-1 needs to be checked or improved becasue it has been generated by TM (Translation Machine).
Question MYSQL Database Insertion
What I want is for a user to fill out a form, and have it inserted into the database. This is for a world of warcraft applicant. Ironically, the code works fine. The tables get inserted, the times are correct, even the thread subject shows up on the kunena category display...
but when I view the category, no topic. What's going on? Here's some snippets from my code:
edit: In addition, I've heard about the Kunena 1.6 api supposedly making this whole process easier, but after looking at the rather limited documentation and fishing around the lib-class files for hours, I didn't find what I was looking for. Hopefully someone can help
Please Log in or Create an account to join the conversation.
In 2.0 creating a new topic will be even easier.
Please Log in or Create an account to join the conversation.
Yes of course, except I really don't know much about how you handle the queries or exactly what your doing here. This just sends me on a wild goose chase to /lib/kunena.posting.class.php, which sends me on another goose chase to some other script. I honestly don't care how Kunena handles its data. It all goes back to the database right? So, I'm querying kunena_categories, kunena_messages and kunena_messages_text. Please take 30 seconds and read my script and tell me what I'm missing rather than sending me off to find the holy grail.
Unless kunena hardcodes it's messages somehow - I don't see a reason why it's not adding the topic to the category.
Please Log in or Create an account to join the conversation.
Even in Kunena 1.6 you need to update other tables to make the topic to show up everywhere.
Your hack:
Do not use $threadid to guess which will be the next id.. Leave thread empty and get the real ID from the database + update message with the right value. And no, not like you're doing now -- there's a PHP function which returns you the last inserted ID.
2) You can do category update by SET numTopics=numTopics+1, numPosts=numPosts+1
3) You need to set also last post information into category table
4) You should also update kunena_users entry: posts=posts+1
Nothing magical in there.. Until you install K2.0, where posting a message will be almost impossible without using our API.
Please Log in or Create an account to join the conversation.
Regardless, the actual issue was that the NEW message id has to MIRROR the new topic id, meaning if you have 4 topics, but 20 messages, the new topic id must be 21 to match the message id.
Anyway - that solved it. Thanks for taking the time anyway.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.