Hi Acid and everybody,
(Sorry, I have to write in English - cause NOBODY would understand ANY german of mine - I read so-so german, so you can post answers in german if you prefer...)
I have installed this great Mod - it works just as intended - thanks, Acid !
I am trying to extend your Mod with a feature on either the index-page or on the search-page:
1. Like you have the
View your posts link (at the upper-right of index-page), I would like to have a
View posts/topics with status XXX - where XXX is a given status-option
or
2. On the search-page - some way? to search for a certain topic-status!
This could of course be used as a (hardcoded) link from index-page as well, and I believe this is the way to go...
Would you, Acid, or anyone else have done something similar..?
In my own attempt to build-in this feature, I have come to this part of the search-page,
below this:
Code: Alles auswählen
else if ( $search_id == 'egosearch' )
{
if ( $userdata['session_logged_in'] )
{
$sql = "SELECT post_id
FROM " . POSTS_TABLE . "
WHERE poster_id = " . $userdata['user_id'];;
}
else
{
header("Location: login.$phpEx?redirect=search.$phpEx&search_id=egosearch", true);
exit;
}
$show_results = 'topics';
$sort_by = 0;
$sort_dir = 'DESC';
}
I added this:
Code: Alles auswählen
else if ( $search_id == 'statussearch' )
{
if ( $userdata['session_logged_in'] )
{
$sql = "SELECT post_id
FROM " . TOPICS_TABLE . "
WHERE topic_info = MY_STATUS";
}
else
{
header("Location: login.$phpEx?redirect=search.$phpEx&search_id=statussearch", true);
exit;
}
$show_results = 'topics';
$sort_by = 0;
$sort_dir = 'DESC';
}
, where MY_STATUS is the status I want to search for.
I know that this does not work correct, and that this is only a part of what should be done in search.php, but this must be the essential part.
Any feedback would be highly appreciated !
- Jesper (as in Copenhagen, DK)