Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Search Filters for Solved Topics #3

Open
4 tasks
tierra opened this issue Feb 16, 2015 · 4 comments
Open
4 tasks

Add Search Filters for Solved Topics #3

tierra opened this issue Feb 16, 2015 · 4 comments

Comments

@tierra
Copy link
Owner

tierra commented Feb 16, 2015

Searching by solved topics forced display of results by topic and not by posts. It might be possible to support both options, but should at least support results by topic. This involves the following sub-tasks:

  • Add yes/no option to advanced search form.
  • Add SQL condition in keyword_search() for each search engine.
  • Add SQL condition in author_search() for each search engine.
  • Add unsolved_topics and your_unsolved_topics quick searches.

Note that the search results already show the solved indicators in both topic and post display modes.

@tierra
Copy link
Owner Author

tierra commented Feb 16, 2015

Currently, phpBB 3.1.3 does not contain the hooks necessary to add the solved search conditions to each search engine, so this is blocked. It will require patches to phpBB upstream to add the necessary hooks.

@SupBob
Copy link

SupBob commented Feb 26, 2015

I have no skills in this area but it is a needed feature and I want to help.

If I were to look for someone that could help with this, what skills should I look for?

And specifically, what are the hooks that are missing in phpBB? Perhaps I can get a feature request going with the phpBB guys.

@tierra
Copy link
Owner Author

tierra commented Feb 26, 2015

These are specifically going to be "core events" (not "template events"), but the process is pretty much the same either way:
http://area51.phpbb.com/phpBB/viewtopic.php?f=111&t=42685

It's also worth noting that any patches being submitting to phpBB should wait until I've had a chance to test those patches with this extension first. It would be a shame to get new hooks added just to find out that they aren't adequate to implement this feature.

I can't tell you exactly which events are missing because we don't really know yet what kind of events will make the search engines the most flexible for other extensions as well. That needs to be discussed with the core phpBB team as well. They will only accept new events if they are useful for all extension authors, not just one extension.

@tierra
Copy link
Owner Author

tierra commented Feb 26, 2015

I'm just going to repeat some of the discussion we had on this topic on the phpBB forums for anyone else catching up on this issue:

I haven't started work on it besides taking a quick look at it to figure out that it needs new events. Each class derived from \phpbb\search\base needs these hooks inside of keyword_search() and author_search() since it needs to be able to modify the SQL search query. The events need to be the same in each fulltext search engine, so each of these files will need them:

phpbb/search/fulltext_mysql.php
phpbb/search/fulltext_native.php
phpbb/search/fulltext_postgres.php
phpbb/search/fulltext_sphinx.php

I'm a bit over my own head on how to implement the Sphinx engine changes, but if we get that far, we can just disable the feature if the forums are using Sphinx for now. The original MOD only supported the MySQL and native engines anyway, though I don't think Sphinx was possible in 3.0.x either.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants