Skip to main content
Recent Posts
Addons / Re: [ADDON][beta] Topic Prefix
Last post by Spuds -
I think I found it .... its a stupid error made when editing the MessageIndex.controller.php

Open that file and go to line 714 ... you should see a } ... just delete that as there are 1 to many now.

I've attached a new version which fixes the above error, so uninstall, delete and use this package instead.  It has a couple of the other improvements as well.
Addons / Re: [ADDON][beta] Topic Prefix
Last post by Spuds -
Well TBH at the moment I can't see how that is even possible ... I've removed the package since its broken, but I'm not seeing any errors on my install sooooo I'm at a dead end.
Addons / Re: [ADDON][beta] Topic Prefix
Last post by Spuds -
Well that makes no sense .... I protected that function, maybe its some stupid PHP level issue, try this one.
Addons / Re: [ADDON][beta] Topic Prefix
Last post by radu81 -
There is something wrong with the version you just posted, I got a db error when I try to enter in a board or view a topic, I get a white screen with this message:
Code: [Select]
  Fatal error: Uncaught Elk_Exception: The database value you're trying to insert does not exist: group_list in /....//public/sources/database/Db-abstract.class.php:404 Stack trace: #0 /....//public/sources/database/Db-abstract.class.php(102): Database_Abstract->error_backtrace('The database va...', 'The database va...', 256, '/srv/users/serv...', 1231) #1 [internal function]: Database_Abstract->replacement__callback(Array) #2 /....//public/sources/database/Db-mysql.class.php(180): preg_replace_callback('~{([a-z_]+)(?::...', Array, '\n\t\tSELECT b.id_...') #3 /....//public/sources/Security.php(1231): Database_MySQL->query('', '\n\t\tSELECT b.id_...', Array) #4 /....//public/sources/subs/Moderation.subs.php(250): boardsAllowedTo(Array) #5 /....//public/themes/default/Theme.php(847): loadModeratorMenuCounts() #6 /srv/users/serverpilot/apps/sko in /....//public/sources/database/Db-abstract.class.php on line 404
I removed the full path to my forum

In elkarte log I have:
Type of error: Critical
Database error, given array of integer values is empty. (current_topic)
Function: topicAttribute
File: /sources/subs/Topic.subs.php
Line: 1962

== edit ==
I checked the table topic_prefix and there are no duplicates (exported in csv then checked with Libreoffice Calc)
Addons / Re: [ADDON][beta] Topic Prefix
Last post by Spuds -
If I go to a board and select a prefix from the list, I see correctly the first page with filtered topics, but I also get the page number to see other pages. The page number should not be present since there are less than 10 topics with that prefix from that board. If I click on next page I get the other topics with the same prefix but from other boards.
Here a screenshot, as you can see there are only two topics with selected prefix, and I get seven pages of results.
[attach type=thumb]6413[/attach]
I could not repo this one ... but I could have been doing things wrong as well.  Please also check your topic_prefix table and make sure there are not duplicate topics, I did see that happen on my local but I thought it was a debug/testing issue.

The only way you should see multiple boards listed is when you select the "Prefix List" from the bread crumbs, for there you can list all topics, across boards, that a prefix was used on.  Once in a board the filtering should be for that board only.
In board view, if I select a prefix from a topic (see the red arrow) I get as results topics from all boards:
[attach type=thumb]6415[/attach]
This should be fixed now
Imho the links from prefixes should all have the "nofollow" attribute, this is not a bug and I could add it myself. Don't know if this was intended or not.
No opinion either way, but I added them ;)
I get a few errors in Elkarte log:

Type: Not specified
Notice: Undefined index: view_num_guests
Line: 85

Tipo di errore: Non specificato
Notice: Undefined index: is_first_post
Line: 55

The second error has "action=quotefast" which could be related to Quick quote add-on
The first one should be fixed now