Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: dougiefresh on October 06, 2006, 12:19:19 AM

Title: View Single Category
Post by: dougiefresh on October 06, 2006, 12:19:19 AM
Link to Mod (https://custom.simplemachines.org/mods/index.php?mod=486)


VIEW SINGLE CATEGORY v2.9
Written by SleePy (http://www.simplemachines.org/community/index.php?action=profile;u=29084)
Taken Over By Dougiefresh (http://www.simplemachines.org/community/index.php?action=profile;u=253913) -> Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=486)


Introduction
This Mod Adds the Ability to view all boards in a single category.
When you are on BoardIndex Clicking CatName will allow you to view that Category. Collapsible Categories are still usable via the Link image to the left of Catname.
As well when you are viewing a board clicking the Category name will bring up the boards in the Category.
Multiple Categories are supported with a comma separated array.

Admin Settings
There are no admin settings.  To disable it, you must remove this mod.

Compatibility Notes
This mod was tested on SMF 2.0.9, but should work on SMF 2.1 RC2, as well as SMF 2.0 and up.  SMF 1.x is not and will not be supported.

DO NOT INSTALL IF:
o In ./Themes/default/scripts/script.js, the first operation can be skipped if the second is successful.

Attach the affected file to this topic (http://www.simplemachines.org/community/index.php?topic=118299.0) for further assistance installing this.

Changelog
The changelog can be viewed at XPtsp.com (http://www.xptsp.com/board/free-modifications/view-single-category/?tab=1).

License
Copyright (c) 2015 - 2019, SleePy, Douglas Orend
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Title: Re: View Single Category
Post by: codenaught on October 06, 2006, 12:23:27 AM
Nice mod. :)

A couple of things you may want to address at some point:

There is a file .DS_Store included in the package that isn't needed.
When viewing a category alone, the boards are no longer in the same order as the order they are assigned in Manage Boards.
Title: Re: View Single Category
Post by: SleePy on October 06, 2006, 06:07:05 PM
akabugeyes,

The .DS_Store just came from my mac when I made the .tar.gz file. I fixed my stuffit preferences so it shouldn't do that anymore.. But no harm done with it. Just a index file like thums_db file you get on windows for thumbnails.

I will have to investigate why the order gets changed. Nothing the mod changes should affect this, But I see it now that you pointed this out.

**Edit**
Found the Bug.
Some Reason SMF wants to ignore the boardorder when viewing a Category, But not when Viewing BoardIndex.
Updated to 1.3

If you Don't want to update just do this..

Edit: /Sources/BoardIndex.php

Find:
Code: [Select]
. (isset($_REQUEST['f']) ? "
AND c.ID_CAT = ".$_REQUEST['f'] : ''), __FILE__, __LINE__);

Replace:
Code: [Select]
. (isset($_REQUEST['f']) ? "
AND c.ID_CAT = ".$_REQUEST['f']."
ORDER BY boardOrder ASC" : ''), __FILE__, __LINE__);

And that sets the boards to be ordered how they should be.
Also The 1.3 Doesn't have .DS_Store. Even though its not a worry.
Title: Re: View Single Category
Post by: fiver on October 08, 2006, 04:54:35 AM
Thanks SleePy,

When I first started using smf a year ago, I thought the category was 'malfunction' when it didn't go into a single category.  ::)

Thanks for making this mod.

Just some notes for user...

1. When in single category and you click "Mark ALL messages as read", it still marks all messages of the whole forum, not just this category. This is convenient as I guess no user would want to have to mark each category separately.

2. After clicking "Mark ALL messages as read", it will bring user back to the forum home page, not the single category page.

 :)

Title: Re: View Single Category
Post by: fiver on October 08, 2006, 05:02:01 AM
I have just browsed through my website again and felt that something is missing.... ie. a way for user to jump to other categories.

Is it possible to add a "jump to" selector somewhere in the single category please?

Thanks ;)
Title: Re: View Single Category
Post by: SleePy on October 08, 2006, 01:38:44 PM
Thanks SleePy,

When I first started using smf a year ago, I thought the category was 'malfunction' when it didn't go into a single category.  ::)

Thanks for making this mod.

Just some notes for user...

1. When in single category and you click "Mark ALL messages as read", it still marks all messages of the whole forum, not just this category. This is convenient as I guess no user would want to have to mark each category separately.

2. After clicking "Mark ALL messages as read", it will bring user back to the forum home page, not the single category page.

 :)

Your Welcome.
That is Normal Behavior. I did Not touch the mark All Messages function while making this mod.

I have just browsed through my website again and felt that something is missing.... ie. a way for user to jump to other categories.

Is it possible to add a "jump to" selector somewhere in the single category please?

Thanks ;)

It is possible. But then it Ruins the Theme Compliance as not every theme will have the Same coding for the BoardIndex.template.php

Though it is very possible. Just borrow the code from MessageIndex.template.php and put it in a if statement to only show when viewing a single category is very possible.

If you want this I can go Get it working and tell you what to change.
Title: Re: View Single Category
Post by: fiver on October 08, 2006, 02:01:30 PM
Quote
If you want this I can go Get it working and tell you what to change.
Yes, please :D Really appreciate your help.

I think it will look good and logical if it is placed immediately after the Single Category and before the Info Center.

Thank you so much.
Title: Re: View Single Category
Post by: fiver on October 08, 2006, 02:17:42 PM
This mod really works! It even goes to Single Category when I clicked on the 'breadcrumb" links like
Forum > Category > Board
Forum > Category > Board > Topic

*thumbsup!* ;D

Regarding "Jump to" selector, I tried the "Jump to" (both in board and in topic) and when I select the drop-down category, it goes to the homepage's category.

Is it possible to jump to Single Category as well?  :P
Title: Re: View Single Category
Post by: fiver on October 08, 2006, 02:41:19 PM
Hi SleePy,

Hope you don't mind another feedback  :P

In the Single Category view, when I click collapse [ - ] it goes to the homepage's category and it is collapsed.

In the Single Category view while it is collapsed, when I click expand [ + ] it goes to the homepage's category and is expanded.

Is it possible to collapse and expand within Single Category view?

 :)

[Last Edit]Perhaps it is not necessary to collapse and expand in Single Category. Therefore removing the 'collapse' and 'expand' buttons might be a better and easier solution?
Title: Re: View Single Category
Post by: SleePy on October 09, 2006, 07:22:16 PM
Well Instead of specially coding just for viewing a single category to remove the expand/collapse feature it was easier to leave it. It acts as a way to get back to the homepage as well kinda for those lazy people  :P
Not much of an issue and keeps it more theme compatiable.

The Breadcrumb was in there from the start  ;) I didn't think about the jumpto.

I got 1.4 working which has the jumpto and a uninstall bug fixed but My localhost test site is giving me problems right now for some reason... So I can't test it right now. So hopefully when I get that fixed and working correctly I will be able to release that. I dont want to release it untested because of the template changes I need to make sure are done right (for normal and TinyPortal).
Though as hard as I worked I am sure the boardindex.template.php change part will fail on a few custom themes. The Change I did to the message template Should not fail unless the jumpto box as previously edited or is removed.

--Edit--
Finally got my localhost site working and was able to test it. Glad I did because there was some errors :(

It Changes the Display.template.php, MessageIndex.template.php and BoardIndex.template.php
And It only does this to the Default Theme (for 1.1 RC3). The changes to them are really simple. Just addition of the Jumpto in BoardIndex and the others just fix it so the jumpto works correctly.
Title: Re: View Single Category
Post by: fiver on October 10, 2006, 03:07:29 AM

Quote
Installing this package will perform the following actions:    Type   Action   Description
1.   Execute Modification   ./Sources/BoardIndex.php   Test failed
2.   Execute Modification   ./Sources/Load.php   Test successful


Yes, I got the above error while uninstalling 1.3. Is it safe to go ahead and uninstall it? Can't wait to try 1.4 with the jumpto.

 :)
Title: Re: View Single Category
Post by: SleePy on October 10, 2006, 10:15:10 AM
I found that error myself to while uninstalling 1.3.. Otherwise I might not of caught..
If you got no other mods that change the boardindex.php source file it is safe to uninstall it and then upload a fresh copy of boardindex.php.. Otherwise I could code up quickly a uninstaller package for you to remove it correctly..
If you want you could use 1.4. edit installed.list and change the version to 1.4. It will think its installed. then uninstall it. Ignore the errors about the other files and boardindex.php and load.php sources should come up sucuessful. then once its uninstalled install it.  ;)
Title: Re: View Single Category
Post by: kimba on October 31, 2006, 05:18:04 PM
I'm curious to know how the yoursite.com URL relates to the mod. I went to the site and did a bit of testing but it was nothing like a forum's page ...
Title: Re: View Single Category
Post by: SleePy on October 31, 2006, 06:41:35 PM
It was just an example of how to access the mod Manually..
But we talked this out through pm.. So its sorted :)
Title: Re: View Single Category
Post by: Metal_GunBlade on February 04, 2007, 02:37:08 PM
Dude, I have installed this mod but I don't know how to make it work, you see I want the guests to be able to see the boards and topics but not able to read them... how can this be accomplished???
Title: Re: View Single Category
Post by: SleePy on February 04, 2007, 02:51:05 PM
This mod would not accomplish that.

This mod basicly lets you view a single category. Which is like the Simple Machines, SMF Support, SMF Development seen here but you can view only that one and all boards under it. This is done through url action and doesn't have any affect on allowing guests to see all boards/topics but not view them.
Title: Re: View Single Category
Post by: Metal_GunBlade on February 05, 2007, 02:37:13 AM
That's odd, a SMF developer directed me here...

Anyway, thanks for your time...
Title: Re: View Single Category
Post by: arez on February 22, 2007, 08:16:55 AM
hi,
i really like this mod and its very usefull to me but there is one thing iam wondering about : i is possible to view multiple categories with this? like
http://localhost/index.php?action=forum;f=1,2,3
?
if not, what needs to be done to get this?
thanks

arez
Title: Re: View Single Category
Post by: SleePy on February 22, 2007, 05:25:41 PM
hi,
i really like this mod and its very usefull to me but there is one thing iam wondering about : i is possible to view multiple categories with this? like
http://localhost/index.php?action=forum;f=1,2,3
?
if not, what needs to be done to get this?
thanks

arez

At this time I have not publicly released a way to do this. I am working on it but as I said have not done a public release due to stability of it.

You can attempt this yourself all the code you need to edit to do this is in the BoardIndex.php in sources. really all you need to do is make it catch the input as an array and validate it then explode the array in the query.
Title: Re: View Single Category
Post by: kimba on May 02, 2007, 08:08:21 PM
I have a slight problem trying to download this mod with the mod package. I'm trying to download the file but my computer automatically asks if I want to decompress the tar file but won't let me upload the actual tar.gz file from my desktop.

When I decompress the file within, it's telling me that it's the wrong file format. Help!
Title: Re: View Single Category
Post by: SleePy on May 03, 2007, 04:50:45 PM
So are you saying when you download it your computer automatically decompresses it? Do you have the original still to upload? Did you try to repackage what it decompressed (it can be a zip file if you want).
Title: Re: View Single Category
Post by: kimba on May 03, 2007, 07:36:04 PM
The computers asks me if I want to decompress it. When I say yes, it shows me all the files within the tar file. When I say no, it just shows the tar file.

The problem with downloading the original file for me is that it doesn't actually show up in my desktop [the tar.gz file]. I'm actually not sure how to repackage a tar file into a zip file.
Title: Re: View Single Category
Post by: kimba on May 03, 2007, 07:50:35 PM
I seem to be talking without trying. I have a tendency to do that  :-[ I've worked it out.
Title: Re: View Single Category
Post by: hein on May 09, 2007, 09:50:22 PM
hi there, great mod, thanks a lot for your work..

emm, i think i found a little  bug...
my english sucks, so i will try to explain the best i can...

when you are viewing a topic or forum....
and click on the category name on the link_tree (site > forum > "category" > forum > topic.....)
it point to "http://sitename/index.php?f=1".... so it goes back to the forum.. not the category...
i think it should point to "http://sitename/index.php?action=forum;f=1"

hope its clear.. enough at least...

thats it..

greetings..
Title: Re: View Single Category
Post by: SleePy on May 09, 2007, 10:02:43 PM
Are you using TinyPortal?
Title: Re: View Single Category
Post by: SleePy on May 09, 2007, 10:13:09 PM
Oh. I see where this happens.

Open Load.php and find:
Code: [Select]
// This is cheating but TinyPortal Modifies this as well.
                // Build up the linktree
$context['linktree'] = array_merge(
$context['linktree'],
array(array(
'url' => $scripturl . '?' . (!empty($context['TPortal']) ? 'action=forum;' : '') . 'f=' . $board_info['cat']['id'],
                                'name' => $board_info['cat']['name']
                        )),

Replace with:
Code: [Select]
// This is cheating but TinyPortal Modifies this as well.
                // Build up the linktree
$context['linktree'] = array_merge(
$context['linktree'],
array(array(
'url' => $scripturl . '?' . (!empty($context['linktree'][0]['name']) && $context['linktree'][0]['name'] == 'Forum' ? 'action=forum;' : '') . 'f=' . $board_info['cat']['id'],
                                'name' => $board_info['cat']['name']
                        )),

That should fix the problem.

I forgot that $context['TPortal'] isn't loaded yet when Load.php is called. Doing that fixs the problem.
I will update the mod package soon if you want to install the mod again instead of manual fix.
Title: Re: View Single Category
Post by: hein on May 10, 2007, 03:28:36 AM
hi there..
yes i use tinyportal...
but.. the fix doesnt work...
tried a couple of times.. to recheck.. but still not working..
Title: Re: View Single Category
Post by: SleePy on May 10, 2007, 06:07:29 PM
Can I have a link to your forum?
Title: Re: View Single Category
Post by: hein on May 10, 2007, 10:55:37 PM
Can I have a link to your forum?
yep, here it is : http://hein.grinhost.net
to test what i say go to a topic, then try te get back to the category through the linktree.
the forum has almost not content because i am preparing the inferface first..
greetings
Title: Re: View Single Category
Post by: SleePy on May 11, 2007, 04:53:32 PM
Reverse the changes and uninstall the mod.
Then download the new one.
That is the only change I made to fix this (and it is working with that change on my test installs) so it might not be installed right.
btw. look at your site in Firefox 2.0. To me some things are appearing weird.
Title: Re: View Single Category
Post by: hein on May 11, 2007, 06:25:34 PM
ok, will do that
thanks for the help
and about my site, i know about the weird things.. its just i am heavily modificating the theme
and errors come often..
i keep testing on firefox and ie.. for checking everything
thanks again
Title: Re: View Single Category
Post by: Smoky "Rider" Blue on March 22, 2008, 12:54:01 AM
I just grabed the one for the beta and will play with it, thanks Sleepy.. ;)
Title: Re: View Single Category
Post by: Metal_13 on May 05, 2008, 08:27:08 AM
im using SMF 2.... why am i getting this error?
the files isnt currupt and its for smf 2 so whats wrong?  i  really need this mod.. how can i fix this....

The package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Title: Re: View Single Category
Post by: SleePy on May 05, 2008, 09:44:14 PM
Which version of SMF are you using?
I have not updated the packages to work with 2.0 Beta 3.1 yet. They should work though by emulating the version of "2.0 Beta 3".
Title: Re: View Single Category
Post by: Manu.G on May 12, 2008, 06:19:29 AM
Hi,

I really love your mod and we were using it till the day we installed the Simple Portal
http://custom.simplemachines.org/mods/index.php?mod=1104 (http://custom.simplemachines.org/mods/index.php?mod=1104) with the Portal your mod wasn't working as it should. That's why we uninstalled it. Today I wanted to install it again, cause the author of the Portal mod posted a code to make your mod working with the Portal.
The only file which is causing trouble is the Load.php.
Now I want to ask you, can you please take a look at our Load.php and help to fix the error, so I can install the mod again in our forum?
Title: Re: View Single Category
Post by: SleePy on May 12, 2008, 10:02:41 PM
I made the change manually to the Load.php that this mod needs.

While your installing it will still say an error occurred for the Load.php
If the Load.php is the only file that files and you have replaced your Load.php with the attached one. Then you can click apply.

Note, you may want to keep a backup of your Load.php as if you want to uninstall the mod you still won't remove all its functionality.
Title: Re: View Single Category
Post by: miguelito on May 28, 2008, 03:32:29 AM
great mod, I think it must be in the core of smf.

using 2.0 beta public 3.1

download and install: no problem (if you change compatibility to "2.0 beta public" )

there is only a 'minibug'.

if you use multiple categories parameter ( hope i´m using it correctly )
example:
http://foro.cometas.info/index.php/c,18,21.html
it shows you both categories: Great!.
but if you use the collapse category button, it back to 'all categories' listing.

is it possible to keep the parameter of the cat_id´s that you wanna see in this case?

thanks.
Title: Re: View Single Category
Post by: Chopper on May 28, 2008, 06:13:05 AM
How do you activate this mod? I have installed it but notice no difference. Can anyone help please?

Thanks
Title: Re: View Single Category
Post by: miguelito on May 28, 2008, 06:28:30 AM
in your forum index:
WITHOUT the mod: if you click in the name of a category: toogles visibility of that category ( srink/expand the boards of this cat )
WITH the mod: the click reload index with only that category.

also, you can make a direct link to an index with the categories you wanna see, por example: ( real link to my forum: http://foro.cometas.info/index.php/c,3,18.html (http://foro.cometas.info/index.php/c,3,18.html) ) will show only 2 categories


hope it helps.
Title: Re: View Single Category
Post by: Chopper on May 28, 2008, 08:48:54 AM
Nope, sorry this makes no sense to me im afraid. Im new to all this you see.
Title: Re: View Single Category
Post by: SleePy on May 29, 2008, 12:01:56 AM
miguelito,

It may be possible. I will add it into my notes for when I am working on updating my mod. I think the best way to do that would be to capture the current url and then store it with those collapse links using c_redirect or something similar.
Title: Re: View Single Category
Post by: miguelito on May 29, 2008, 02:35:08 AM
good, but it´s those 'collapse links' work to keep the url they came from and do not change nothing,

it´s no problem of your mod.
Title: Re: View Single Category
Post by: Pepsi Lex on July 07, 2008, 11:21:12 PM
pls help
i cant get this mod working and i am using tinyportal

and i cant make the changes to BoardIndex.template.php of my custom theme

here is my BoardIndex.template.php

Title: Re: View Single Category
Post by: SleePy on July 08, 2008, 12:00:38 AM
What isn't working?

This mod doesn't currently do many edits to the boardindex other than adding a jumpto while using a single category.
Title: Re: View Single Category
Post by: Pepsi Lex on July 08, 2008, 12:51:16 AM
it doesn't show the single categories
nothing happens even if i ues the ?f=(catid) link...

pls help me
Title: Re: View Single Category
Post by: SleePy on July 08, 2008, 07:10:01 PM
Did you try to click on a category name?

Title: Re: View Single Category
Post by: jepot5 on July 11, 2008, 05:09:04 AM
its now working
but what i want to do is hide my shoutbox whenever i am viewing a category
Title: Re: View Single Category
Post by: SleePy on July 11, 2008, 12:22:09 PM
You would need to ask the author of the shoutbox for specific details.
But the variable my mod uses is "$context['single_cats']"

That is set when you are viewing a single category(ies).
Title: Re: View Single Category
Post by: Manu.G on July 31, 2008, 04:54:53 AM
I made the change manually to the Load.php that this mod needs.

While your installing it will still say an error occurred for the Load.php
If the Load.php is the only file that files and you have replaced your Load.php with the attached one. Then you can click apply.

Note, you may want to keep a backup of your Load.php as if you want to uninstall the mod you still won't remove all its functionality.

Sorry for my late reply, but I was a bit busy the last few weeks.
Thanks a lot for your help! :D

May I ask for your help again. It's not a big problem I have and I never realized it before, my second Admin informed me about it.
It has to do with the link tree in the Recent Post part: http://forum.arseniums.com/index.php?action=recent (http://forum.arseniums.com/index.php?action=recent)
When you click at the category name itself, the category doesn't open as single category, can you tell me please which code I have to change?
I tried it alone, but I'm a dumb in php.  :'(
Title: Re: View Single Category
Post by: SleePy on July 31, 2008, 01:08:49 PM
Open Recent.php

Find (about line 175):
Code: [Select]
            $context['linktree'][] = array(
                'url' => $scripturl . '#' . (int) $_REQUEST['c'],
                'name' => $name
            );

Replace:
Code: [Select]
            $context['linktree'][] = array(
                'url' => $scripturl . '?action=forum;c=' . (int) $_REQUEST['c'],
                'name' => $name
            );

Find (about line 555):
Code: [Select]
        $context['linktree'][] = array(
            'url' => $scripturl . '#' . (int) $_REQUEST['c'][0],
            'name' => $name
        );

Replace:

Code: [Select]
        $context['linktree'][] = array(
            'url' => $scripturl . '?action=forum;c=' . (int) $_REQUEST['c'][0],
            'name' => $name
        );

I will fix it in my mod sources though so next time I update the package this should be fixed :)
Title: Re: View Single Category
Post by: Manu.G on July 31, 2008, 03:10:52 PM
I changed the codes, but it's still the same.  :'(
Can it be it has something to do with the Simple Portal we have installed?
Title: Re: View Single Category
Post by: SleePy on July 31, 2008, 06:30:43 PM
Are you sure you uploaded the file?
That is the only two calls to the link tree in that file that set the category.


Try this:

Find:
Code: [Select]
'href' => $scripturl . '#' . $row['ID_CAT'],
'link' => '<a href="' . $scripturl . '#' . $row['ID_CAT'] . '">' . $row['cname'] . '</a>'

Replace:
Code: [Select]
'href' => $scripturl . '?action=forum;c=' . $row['ID_CAT'],
'link' => '<a href="' . $scripturl . '?action=forum;c=' . $row['ID_CAT'] . '">' . $row['cname'] . '</a>'
Title: Re: View Single Category
Post by: Manu.G on August 01, 2008, 04:42:43 AM
Are you sure you uploaded the file?
That is the only two calls to the link tree in that file that set the category.


Try this:

Find:
Code: [Select]
            'href' => $scripturl . '#' . $row['ID_CAT'],
            'link' => '<a href="' . $scripturl . '#' . $row['ID_CAT'] . '">' . $row['cname'] . '</a>'

Replace:
Code: [Select]
            'href' => $scripturl . '?action=forum;c=' . $row['ID_CAT'],
            'link' => '<a href="' . $scripturl . '?action=forum;c=' . $row['ID_CAT'] . '">' . $row['cname'] . '</a>'

After I have changed this part, everything works perfect!! (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fforum.arseniums.com%2FSmileys%2Fdefault%2Fa020.gif&hash=51517b43bddca0c7f4d6836a13a7078d)
Thanks a lot for your help!! :D :D
Title: Re: View Single Category
Post by: goldenboy48 on August 05, 2008, 11:19:09 PM
Works Fine.

After 3 previous installations, first time it went without any errors [but it worke every time, even with errors in installation]

Thank You!!!
Title: Re: View Single Category
Post by: Dejv on November 08, 2008, 07:02:54 PM
Hi,

I have a fresh install of 1.1.7, I couldnt install the package (because of some kind of login problem) so I did a manual install of the latest package and its not working, I've double checked my edits :( ... I can go to admin, I can view a single topic but not the main index.php with the recent posts.
----> this looks like it there is some kind of mistake in the recent posts?

Btw. is it still working with c=# or f=# ? Some older version I had installed before worked with c=#

I've tried the last suggested update for Recent.php
Code: [Select]
'href' => $scripturl . '?action=forum;c=' . $row['ID_CAT'],
'link' => '<a href="' . $scripturl . '?action=forum;c=' . $row['ID_CAT'] . '">' . $row['cname'] . '</a>'
but it didn't help

Thanks a lot for any help!
Title: Re: View Single Category
Post by: SleePy on November 09, 2008, 11:18:37 AM
f=# no longer works, it is now c=#. I changed this as using f made no sense, and SMF uses c for all its category things, so it just made sense.

I am lost at your issue though? This only makes it so you can view a single category at a time. This doesn't change the unread or recent posts. Although you can specify in recent and unread posts to only get those from a category.
Title: Re: View Single Category
Post by: Dejv on November 09, 2008, 06:05:17 PM
Just wanted to say that as far as for me, the v2.1.1 works with smf1.1.7, version 2.1.4 doesn't (or maybe I need some php or mysql update even though I've updated it just a few months ago).
Well, never mind, I'll stay using the old one.

Btw: Thanks a lot for this mod!!!  :)
Title: Re: View Single Category
Post by: pariofdreamz on November 24, 2008, 09:41:30 AM
I m too Facing The Same Problem as Dejv Above....... Can Any One Help Please

Dejv Please do me a favour please give me the link from where i can get the old version of single category which is working with 1.1.7.

- Pari
Title: Re: View Single Category
Post by: SleePy on November 24, 2008, 06:42:09 PM
Hmm, what exactly doesn't work?

Did you check to see if it was only affected for that theme?

If not, I will have to install it on 1.1.7, I don't have it running on any 1.1 forum of mine.
Title: Re: View Single Category
Post by: shumilica on January 22, 2009, 10:37:13 PM
Can you put here the version for 2.0 beta 3.1 public? I won't ask for support :)
I ask this because the current version doesn't work for smf 2 beta 3.1, only for beta 4. I can change the xml file but i don't know if your new code of this last version is compatible with beta 3.1.
Thanks in advance for response.
Title: Re: View Single Category
Post by: SleePy on January 24, 2009, 07:05:56 PM
I do keep previous versions on my own site. Although I really suggest you update to the latest version as there was security fixes for that version.
Title: Re: View Single Category
Post by: Enders on February 03, 2009, 12:11:46 PM
im also having issues with unread posts and stuff after installation =/
Title: Re: View Single Category
Post by: SleePy on February 05, 2009, 07:00:24 PM
What is wrong with recent posts? You want that to show only a single post?
Title: Re: View Single Category
Post by: shumilica on February 12, 2009, 07:59:30 PM
I have upgraded SMF to RC1. Is this mod compatible? And if not, when do you think you will have time to do the changes?
Thanks
Title: Re: View Single Category
Post by: Enders on February 13, 2009, 01:52:29 AM
Recent post gets an error "tstring mismatch"
Title: Re: View Single Category
Post by: SleePy on February 15, 2009, 12:09:07 PM
shumilica,

It should work in 2.0 RC1, though it appears from my notes (As I test my mods on svn versions a lot) that there is a replacement issue that may cause the mod installation to fail. I am working on getting my mods updated and released today for RC1 :) I can't say when, this depends on time and how complex it is to fix other issues in other mods.

Enders,
What is this exact error?
Are you using 2.0 RC1?
Title: Re: View Single Category
Post by: Enders on February 19, 2009, 12:58:22 PM
Never mind.. I fixed it. The "shared forum mod" seems to be interfering with it.
Title: Re: View Single Category
Post by: codnerd on March 13, 2009, 08:28:29 PM
Ok. I just installed on my site, and it does not work.
When installing, it shows that 2 files shown errors.
I manually put the code in, and it is still not working...

Manually coded files are attached.
Title: Re: View Single Category
Post by: codnerd on March 14, 2009, 03:11:05 PM
Still need help...
Title: Re: View Single Category
Post by: codnerd on March 16, 2009, 07:26:31 PM
Anyone?
Title: Re: View Single Category
Post by: WVPreacher on March 18, 2009, 11:01:19 PM
I am also having issues with this mod not working.  It installed successfully, but has made no difference.  Clicking on the category takes me to my portal.

Does this need to be turned on somewhere???  I've looked, but haven't been able to find it.

I just want to say that I have had real good luck with Sleepy's mods, so I'm not complaining. :)  But I would absolutely love to get this one working.
Title: Re: View Single Category
Post by: Dejv on March 21, 2009, 07:16:20 AM
Mine works for 1.1.8

For example this works if I need to display only categories 1 and 6 ..../forum/index.php?c=1,6

But it just doesnt work when I click on a single category, there is no difference.
Title: Re: View Single Category
Post by: Leonta on March 30, 2009, 03:44:57 PM
I am also having issues with this mod not working.  It installed successfully, but has made no difference.  Clicking on the category takes me to my portal.

Does this need to be turned on somewhere???  I've looked, but haven't been able to find it.

I just want to say that I have had real good luck with Sleepy's mods, so I'm not complaining. :)  But I would absolutely love to get this one working.

I have same problem, using ezportal :(
*I think the problem is at Load.php I have included mine at this post. Can you please have a look ? Many thanks.
Title: Re: View Single Category
Post by: PalmBeachPreps on April 08, 2009, 03:36:19 AM
Great mod, works perfectly for me with 1.1.8!
Title: Re: View Single Category
Post by: bjraines on May 18, 2009, 07:54:25 PM
great mod, is there a way to get it to work with Pretty URLs?

or at the very least have the title of the category pulled into the page title of each category page?
Title: Re: View Single Category
Post by: cubetgio on May 24, 2009, 11:19:00 PM
Parse error: syntax error, unexpected '*' in /srv/d_matixadev/www/giovanni.matixa.eu/htdocs/Sources/Load.php on line 675

That 's the error message i have got using ez-portal 1.1.9

could you take this in account for the next upgrade?

It's a very usefull mod, thanks.
Title: Re: View Single Category
Post by: djkmmo on May 28, 2009, 09:46:41 AM
I have tried to install this mod in 1.1.19 but it doesn't seem to be compatible (the first comment in BoardIndex.php doesn't exist). Any chance of an update for 1.1.19?
Title: Re: View Single Category
Post by: aw06 on November 04, 2009, 08:52:57 AM
I'm trying to install this on 1.1.10 .. it's telling me the package is currupted  :o ???
Title: Re: View Single Category
Post by: SleePy on November 05, 2009, 09:48:11 PM
Are you sure it is saying corrupted or is it also saying not for your version of SMF?  You may need to emulate your version as 1.1.9 due to a bug in SMF
Title: Re: View Single Category
Post by: Hoodie on November 21, 2009, 03:56:40 AM
Quote from: An Error Has Occurred!
Package upload failed due to the following error:
"Although the package was downloaded to the server it appears to beempty. Please check the Packages directory, and the "temp"sub-directory are both writable. If you continue to experience thisproblem you should try extracting the package on your PC and uploadingthe extracted files into a subdirectory in your Packages directory andtry again. For example, if the package was called shout.tar.gz youshould:
1) Download the package to your local PC and extract it into files.
2) Using an FTP client create a new directory in your "Packages" folder, in this example you may call it "shout".
3) Upload all the files from the extracted package to this directory.
4) Go back to the package manager browse page and the package will be automatically found by SMF."

That's what I get whenever I try to install through package manager..  When I try to open it in WinRAR, it says it can't be opened..
Title: Re: View Single Category
Post by: SleePy on November 21, 2009, 07:48:15 PM
As said in the other topic, please try again :)
Title: Re: View Single Category
Post by: scoops09 on December 08, 2009, 07:45:18 PM
Ok I just found this mod a couple days ago and it's exactly what I've been needing. However, I am having an issue and I apologize if it has already been asked.

I'm running the PortaMx portal and when I click on a category it just brings me to my portal page. The mod works perfectly when I turn off the portal but that isn't an option. I even tried it with other portals but the same thing happened.

I'm very much a novice when it comes to coding, so can someone tell me/show me what I need to do to fix this? I'm so excited about this mod! I can't stress enough how much this mod means to me & my site!

Thanks in advance for any help.
Title: Re: View Single Category
Post by: Hoodie on December 08, 2009, 09:55:26 PM
Ok I just found this mod a couple days ago and it's exactly what I've been needing. However, I am having an issue and I apologize if it has already been asked.

I'm running the PortaMx portal and when I click on a category it just brings me to my portal page. The mod works perfectly when I turn off the portal but that isn't an option. I even tried it with other portals but the same thing happened.

I'm very much a novice when it comes to coding, so can someone tell me/show me what I need to do to fix this? I'm so excited about this mod! I can't stress enough how much this mod means to me & my site!

Thanks in advance for any help.

I'm getting the same thing using PortaMX..
Title: Re: View Single Category
Post by: scoops09 on December 09, 2009, 12:41:21 AM
I'm getting the same thing using PortaMX..

This mod means so much to me that I uninstalled PortaMX and tried Simple Portal & EzPortal but the same thing happened while using those portals as well. I need this mod to work in the worst possible way!

If you find anything out on how to make it work, please let me know. I'll make sure to do the same if I find anything out! I'm hoping someone out there can help!
Title: Re: View Single Category
Post by: SleePy on December 09, 2009, 07:00:45 PM
Give this a try.  Install both mods.

Open BoardIndex.php and find:
Code: [Select]
// Get out of this mess.
redirectexit('c=' . $_REQUEST['c_redirect']);

Then replace that with:
Code: [Select]
// Get out of this mess.
redirectexit((!empty($context['TPortal']) || defined('PortaMx') ? 'action=forum;' : '') . 'c=' . $_REQUEST['c_redirect']);

Let me know if that works.  If it does I will work on fixing this with the rest of the code and update the mod.
Title: Re: View Single Category
Post by: scoops09 on December 10, 2009, 05:29:56 AM
Thanks to SunKing, this problem is solved! This code works on both Simple Portal and PortaMx! I'm not sure exactly what he did so I'm just pasting the entire block he tweaked. I knew this was going to be an awesome mod and boy was I right! This is perfect for people who have a ton of categories & topics - Thanks SleePy!

Code: [Select]
// Run through the categories and boards (or only boards)....
while ($row_board = $smcFunc['db_fetch_assoc']($result_boards))
{
if ($boardIndexOptions['include_categories'])
{
$ignoreThisBoard = in_array($row_board['id_board'], $user_info['ignoreboards']);
$row_board['is_read'] = !empty($row_board['is_read']) || $ignoreThisBoard ? '1' : '0';
// Haven't set this category yet.
if (empty($categories[$row_board['id_cat']]))
{
$categories[$row_board['id_cat']] = array(
'id' => $row_board['id_cat'],
'name' => $row_board['cat_name'],
'is_collapsed' => isset($row_board['can_collapse']) && $row_board['can_collapse'] == 1 && $row_board['is_collapsed'] > 0,
'can_collapse' => isset($row_board['can_collapse']) && $row_board['can_collapse'] == 1,
'collapse_href' => isset($row_board['can_collapse']) ? $scripturl . '?action=collapse;c=' . $row_board['id_cat'] . ';sa=' . ($row_board['is_collapsed'] > 0 ? 'expand' : 'collapse;') . (isset($context['single_cats']) ? ';c_redirect=' . (is_array($_REQUEST['c']) ? implode(',', $_REQUEST['c']) : $_REQUEST['c']) : '') . '#c' . $row_board['id_cat'] : '',

'collapse_image' => isset($row_board['can_collapse']) ? '<img src="' . $settings['images_url'] . '/' . ($row_board['is_collapsed'] > 0 ? 'expand.gif" alt="+"' : 'collapse.gif" alt="-"') . ' border="0" />' : '',
'href' => $scripturl . '?' . (!empty($context['TPortal']) ? 'action=forum;' : '') . 'action=forum;c=' . $row_board['id_cat'],
'boards' => array(),
'new' => false
);
// Single Category Mod Edited This.
            $categories[$row_board['id_cat']]['link'] = '<a id="c' . $row_board['id_cat'] . '" href="' . $categories[$row_board['id_cat']]['href'] . '">' . $row_board['cat_name'] . '</a>';

            // Single Category Mod
            if (isset($context['single_cats']) && !is_array($context['category_selection']))
               $context['linktree'][] = array(
                  'url' => $scripturl . '?' . (!empty($context['TPortal']) ? 'action=forum;' : '') . 'action=forum;c=' . $row_board['id_cat'],
                  'name' => $row_board['cat_name']);
            else
            {
               if(!isset($temp))
                  $temp = array();
               $temp[] = $row_board['cat_name'];
            }
         }
Title: Re: View Single Category
Post by: flickernever on January 10, 2010, 09:27:46 AM
Using SMF 1.1.10 which is compatible I got this message:

Quote
The package you are trying to download or install is either corrupt or not compatible with this version of SMF.

What can be wrong?
Title: Re: View Single Category
Post by: SleePy on January 11, 2010, 06:46:36 PM
This is due to a bug in SMF related to how it handles revisions after x.x.9.  Simply add this to the end of your package manager url: ;version_emulate=1.1.9
Title: Re: View Single Category
Post by: sektor on January 12, 2010, 06:40:37 PM
Hello

Will this mod work on 1.1.11?

Thanx
Title: Re: View Single Category
Post by: sektor on January 13, 2010, 07:21:59 PM
I tried installing the mod using 1.1.9 emulation, but got this error:

Execute Modification   C:\inetpub\wwwroot\public\\smf/Sources/BoardIndex.php   Test failed
Title: Re: View Single Category
Post by: SleePy on January 15, 2010, 06:35:02 PM
Do you have any other mods installed?
Can you list them?
Do you know if any of those modified that file?
Title: Re: View Single Category
Post by: sektor on January 15, 2010, 07:35:46 PM
Do you have any other mods installed?
Can you list them?
Do you know if any of those modified that file?

Yes i do:

Pretty URLs
Thank-O-Matic
Version Emulate Dropdown
Title: Re: View Single Category
Post by: Neverhurry on January 23, 2010, 04:00:22 PM
I just installed but i have the same problem as scoops09.

Give this a try.  Install both mods.

Open BoardIndex.php and find:
Code: [Select]
// Get out of this mess.
redirectexit('c=' . $_REQUEST['c_redirect']);

Then replace that with:
Code: [Select]


// Get out of this mess.
redirectexit((!empty($context['TPortal']) || defined('PortaMx') ? 'action=forum;' : '') . 'c=' . $_REQUEST['c_redirect']);

Let me know if that works.  If it does I will work on fixing this with the rest of the code and update the mod.

Hi, SleePy! I I tried that, but it still does work. I am using smf2.0 rc2 with default theme, what should I do? thanks!

Thanks to SunKing, this problem is solved! This code works on both Simple Portal and PortaMx! I'm not sure exactly what he did so I'm just pasting the entire block he tweaked. I knew this was going to be an awesome mod and boy was I right! This is perfect for people who have a ton of categories & topics - Thanks SleePy!

Code: [Select]
// Run through the categories and boards (or only boards)....
while ($row_board = $smcFunc['db_fetch_assoc']($result_boards))
{
if ($boardIndexOptions['include_categories'])
{
$ignoreThisBoard = in_array($row_board['id_board'], $user_info['ignoreboards']);
$row_board['is_read'] = !empty($row_board['is_read']) || $ignoreThisBoard ? '1' : '0';
// Haven't set this category yet.
if (empty($categories[$row_board['id_cat']]))
{
$categories[$row_board['id_cat']] = array(
'id' => $row_board['id_cat'],
'name' => $row_board['cat_name'],
'is_collapsed' => isset($row_board['can_collapse']) && $row_board['can_collapse'] == 1 && $row_board['is_collapsed'] > 0,
'can_collapse' => isset($row_board['can_collapse']) && $row_board['can_collapse'] == 1,
'collapse_href' => isset($row_board['can_collapse']) ? $scripturl . '?action=collapse;c=' . $row_board['id_cat'] . ';sa=' . ($row_board['is_collapsed'] > 0 ? 'expand' : 'collapse;') . (isset($context['single_cats']) ? ';c_redirect=' . (is_array($_REQUEST['c']) ? implode(',', $_REQUEST['c']) : $_REQUEST['c']) : '') . '#c' . $row_board['id_cat'] : '',

'collapse_image' => isset($row_board['can_collapse']) ? '<img src="' . $settings['images_url'] . '/' . ($row_board['is_collapsed'] > 0 ? 'expand.gif" alt="+"' : 'collapse.gif" alt="-"') . ' border="0" />' : '',
'href' => $scripturl . '?' . (!empty($context['TPortal']) ? 'action=forum;' : '') . 'action=forum;c=' . $row_board['id_cat'],
'boards' => array(),
'new' => false
);
// Single Category Mod Edited This.
            $categories[$row_board['id_cat']]['link'] = '<a id="c' . $row_board['id_cat'] . '" href="' . $categories[$row_board['id_cat']]['href'] . '">' . $row_board['cat_name'] . '</a>';

            // Single Category Mod
            if (isset($context['single_cats']) && !is_array($context['category_selection']))
               $context['linktree'][] = array(
                  'url' => $scripturl . '?' . (!empty($context['TPortal']) ? 'action=forum;' : '') . 'action=forum;c=' . $row_board['id_cat'],
                  'name' => $row_board['cat_name']);
            else
            {
               if(!isset($temp))
                  $temp = array();
               $temp[] = $row_board['cat_name'];
            }
         }

Hi, scoops09, where should i paste this code? thank you!
Title: Re: View Single Category
Post by: maipgeut on April 18, 2010, 05:50:33 AM
I  have this problem,

1.     Executar Modificación     .Sources//BoardIndex.php     Prueba fallida
2.    Executar Modificación    .Sources//Recent.php    Prueba fallida

I try to install manually but i can't find this lines in recent.php:

Code: [Select]
'href' => $scripturl . '#' . $row['ID_CAT'],
'link' => '<a href="' . $scripturl . '#' . $row['ID_CAT'] . '">' . $row['cname'] . '</a>'

and in BoardIndex.php

Code: [Select]
'href' => $scripturl . '#' . $row_board['ID_CAT'],
I have installed the simple portal and i'm using smf 1.1.11

Please any help? I attach this files
Title: Re: View Single Category
Post by: sevamaster on April 20, 2010, 06:36:45 PM
great mod, is there a way to get it to work with Pretty URLs?

or at the very least have the title of the category pulled into the page title of each category page?

I agree. Great mod!
and i want to repeat this question.

Is there a way to get it to work with Pretty URLs?
Title: Re: View Single Category
Post by: Arantor on April 20, 2010, 06:39:07 PM
Since that requires some work on Pretty URLs' part rather than this mod, you'd best ask them.
Title: Re: View Single Category
Post by: Joker™ on June 21, 2010, 12:45:21 PM
first of all the mod is awesome.

i've a little request that how can i disappear the whole category from main board , i.e category is not visible on main board but still accessible if we use the link of category using this mod.

Like
www.mysite.com/index.php?c=1  (this link is still working , but this category is hidden on main board index)

Title: Re: View Single Category
Post by: Joker™ on June 23, 2010, 09:15:24 AM
bump*
Title: Re: View Single Category
Post by: Joker™ on July 01, 2010, 05:57:17 AM
bump*******
Title: Re: View Single Category
Post by: maipgeut on July 07, 2010, 03:27:15 AM
anyone can help me? please sleepy
Title: Re: View Single Category
Post by: samurai-lupin on October 02, 2010, 03:04:55 AM
Hello, this is a very good mod. However I noticed that there seems to be a conflict with the Password Protected Boards Mod:

http://custom.simplemachines.org/mods/index.php?mod=922

When I had installed the Single Category Mod, the Password Protect Boards Mods would no longer appear on my board index ...

Any thoughts what might be the cause?

Thanks!
Title: Re: View Single Category
Post by: Yngwiedis on April 18, 2011, 11:36:18 PM
Can you make this mod compatible with SimplePortal please ?

Thank you very much.
Title: Re: View Single Category
Post by: Manu.G on October 26, 2011, 12:01:28 PM
I would also appreciate it if the mod would be compatible with SimplePortal :)
Title: Re: View Single Category
Post by: GlitchPC on March 26, 2012, 04:38:12 PM
I would also appreciate it if the mod would be compatible with SimplePortal :)

Make that 3...
Title: Re: View Single Category
Post by: MiY4Gi on August 07, 2012, 02:12:44 PM
I'm running SMF 2.0.2. Strange. The package installer requires manual installation of one line in the /Sources/Subs-BoardIndex.php file, however the relevant line in my file is slightly different to the one in the package installer, and I can't tell if it was changed by a mod or not.

The line that the installer wants to change is:

Code: [Select]
$categories[$row_board['id_cat']]['link'] = '<a id="c' . $row_board['id_cat'] . '" href="' . (isset($row_board['can_collapse']) ? $categories[$row_board['id_cat']]['collapse_href'] : $categories[$row_board['id_cat']]['href']) . '">' . $row_board['cat_name'] . '</a>';

But the "same" line in my file is:

Code: [Select]
$categories[$row_board['id_cat']]['link'] = '<a id="c' . $row_board['id_cat'] . '"></a>' . ($categories[$row_board['id_cat']]['can_collapse'] ? '<a href="' . $categories[$row_board['id_cat']]['collapse_href'] . '">' . $row_board['cat_name'] . '</a>' : $row_board['cat_name']);

There's a difference between the two lines of code, but is the difference significant?
Title: Re: View Single Category
Post by: MiY4Gi on August 11, 2012, 09:52:57 AM
Hello?
Title: Re: View Single Category
Post by: FireDitto on February 15, 2013, 07:45:19 AM
Another request for Simple Portal compatibility.
Title: Re: View Single Category
Post by: pixelgeek on February 28, 2013, 05:16:04 PM
I'm running SMF 2.0.2. Strange. The package installer requires manual installation of one line in the /Sources/Subs-BoardIndex.php file, however the relevant line in my file is slightly different to the one in the package installer, and I can't tell if it was changed by a mod or not.

I am running into the same issue. I suspect that between the 2.0 RC releases and the final release that there was a change made in the core code and the mod hasn't been updated accordingly.
Title: Re: View Single Category
Post by: grandinquisitor on March 18, 2013, 12:06:02 PM
Is there a workaround for this?  Or in the alternative, another mod that could accomplish the same?
Title: Re: View Single Category
Post by: Kindred on March 18, 2013, 12:59:44 PM
work around for what?


So, I just installed this mod and found the line/failure mentioned above.
Look at the code...  it's actually doing the exact same thing in both lines of code, it's just worded slightly differently.
What this mod does it it replaces the "collapse" when clicking the catgeory name with a "view the category" when clicking the category name...

So, the short answer is YES.
comment out that one line of code and paste in this new bit as indicated in the error/manual apply window

it works just fine after that.
Title: Re: View Single Category
Post by: grandinquisitor on March 20, 2013, 07:07:08 PM
Thank you!  I was mainly concerned that doing that might break something, but I did exactly as you said and there were zero issues.
Title: Re: View Single Category
Post by: dougiefresh on June 16, 2014, 09:58:20 AM
I am running SMF v2.0.7 and am having problems installing this mod.  I did the change suggested earlier to my Subs-BoardIndex.php file, with package manager reporting success.  However, the QueryString.php source file has been changed sometime since v2.0.2.  Renamed my QueryString.php file and replaced with clean QueryString.php file, same problem.  Anyone made this mod work with v2.0.7?  Or any ideas?  Thanks!
Title: Re: View Single Category
Post by: Kindred on June 16, 2014, 12:59:56 PM
you should NEVER just replace files like that... by doing that, you are potentially undoing or causing errors with other mods.
Title: Re: View Single Category
Post by: dougiefresh on June 18, 2014, 04:12:08 PM
 O:)  ::) The forum I replaced the file on was a local version on my computer, so there was no chance it would wreck the forum.  However, the fact that the same problem was present on a clean copy and the modified copy says (at least to me) that at some point the source file changed.  I need to figure out what/how to change the file so that the mod works.

I guess I could just comment out and replace the effected code like before, but for some reason, it just seems like a tacky thing to do.....   Especially since I don't understand what the code does....
Title: Re: View Single Category
Post by: Geor'G on June 19, 2014, 06:20:50 PM
Error with patch 2.0.8
Code: [Select]
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY b.board_order' at line 23
Line: /.../.../.../.../.../Sources/Subs-BoardIndex.php
Строка: 120
Title: Re: View Single Category
Post by: Kindred on June 19, 2014, 06:35:06 PM
Are you running portamx?
Title: Re: View Single Category
Post by: Geor'G on July 10, 2014, 12:18:58 PM
Yes.
Title: Re: View Single Category
Post by: margarett on July 10, 2014, 12:23:31 PM
And Arantor's MOD  MySQL Board Order Fix (http://custom.simplemachines.org/mods/index.php?mod=3865)?
Title: Re: View Single Category
Post by: Arantor on July 10, 2014, 01:45:22 PM
Or 2.0.8 which conflicts with PortaMX for the exact same reason because it includes my mod's code...
Title: Re: View Single Category
Post by: Geor'G on July 11, 2014, 06:13:57 AM
I corrected so file Subs-BoardIndex.php:
Code: [Select]
WHERE {query_see_board}' . (empty($boardIndexOptions['countChildPosts']) ? (empty($boardIndexOptions['base_level']) ? '' : '
AND b.child_level >= {int:child_level}') : '
AND b.child_level BETWEEN ' . $boardIndexOptions['base_level'] . ' AND ' . ($boardIndexOptions['base_level'] + 1))
. (isset($context['single_cats']) ? "
AND c.id_cat{raw:cat_field}
ORDER BY board_order ASC" : ""),
Removed line:
Code: [Select]
ORDER BY board_order ASC
And it works.
Title: Re: View Single Category
Post by: dougiefresh on July 13, 2014, 09:47:47 PM
I am running SMF v2.0.7 and am having problems installing this mod.  I did the change suggested earlier to my Subs-BoardIndex.php file, with package manager reporting success.  However, the QueryString.php source file has been changed sometime since v2.0.2.  Renamed my QueryString.php file and replaced with clean QueryString.php file, same problem.  Anyone made this mod work with v2.0.7?  Or any ideas?  Thanks!
BUMP..... Now running v2.0.8 with same problem....  Can anybody help me?
Title: Re: View Single Category
Post by: margarett on July 14, 2014, 06:36:16 AM
I'm taking a *WILD* guess because these regex stuff aren't really in my book :P

For the first operation you should find:
Code: [Select]
board|topic)=[^#"]+?)(#[^"]*?)?"~', 'sid_insert__preg_callback', $buffer);And replace with
Code: [Select]
c|board|topic)=[^#"]+?)(#[^"]*?)?"~', 'sid_insert__preg_callback', $buffer);
For the second operation you should find:
Code: [Select]
board|topic)=[^#"]+?)(#[^"]*?)?"~', 'pathinfo_insert__preg_callback', $buffer);And replace with:
Code: [Select]
c|board|topic)=[^#"]+?)(#[^"]*?)?"~', 'pathinfo_insert__preg_callback', $buffer);
Again, this is just a wild guess :P
Title: Re: View Single Category
Post by: Arantor on July 14, 2014, 06:38:29 AM
Looks good to me (assuming the addition of c| is what the mod originally does (which is to ensure that index.php?c= will be recognised in the relevant tests)
Title: Re: View Single Category
Post by: margarett on July 14, 2014, 06:41:20 AM
It is.

Thanks ;)
Title: Re: View Single Category
Post by: dougiefresh on July 14, 2014, 06:57:57 AM
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.montney.com%2Fimages%2Foh.gif&hash=daa5a660ede61c10af70fbbefdee8aa7) (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.montney.com%2Fimages%2Fwow.gif&hash=b97d95443af66623ff70537cfceaa19b)
For the life of me, I just couldn't figure that one out!  Thanks, margarett!  (Yeah, regex stuff isn't my strong suit either...)

Now all we need is an updated mod....  O:) ;D

EDIT: After reviewing the license found in the mod, I decided that I'd make the changes and post them.  Attached is my altered copy of the mod, version 2.1.9a....  Package info file has been modified to use the new XML file for v2.0.8 and up....

EDIT: Packaged file has been removed from attachments.  See here (http://www.simplemachines.org/community/index.php?topic=118299.msg3730739#msg3730739) for unofficial updated version v2.1.9b.
Title: Re: View Single Category
Post by: Steve on August 05, 2014, 08:41:44 AM
Drat. I get an error on the first step with dougiefresh's attachment:

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi1262.photobucket.com%2Falbums%2Fii614%2FOPStuph%2Fall2%2Fsinglecategoryerror85142.png&hash=610a08b2721be7d2c524bdbc5edbff0c)

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi1262.photobucket.com%2Falbums%2Fii614%2FOPStuph%2Fall2%2Fsinglecategoryerror8514.png&hash=277bcfa89177c6fff91865fc545f795a)

And that's on a board with only this installed:

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi1262.photobucket.com%2Falbums%2Fii614%2FOPStuph%2Fall2%2Finstalledmods85141.png&hash=98db174511d09aab2b039ff281679718)

I looked in Sources/Subs-BoardIndex and there is no cat_field in there anywhere. :(
Title: Re: View Single Category
Post by: dougiefresh on August 11, 2014, 07:19:26 PM
Okay, I'm sorry about the late reply.  I've rebuilt my copy of this mod and have attached it.  These are the mods I've done to v2.1.9 - ONLY FOR SMF v2.0.8+:
o Operation # 5 (Sub-BoardIndex.php) (http://www.simplemachines.org/community/index.php?topic=118299.msg3386342#msg3386342) replacement
o Operation # 3 (Sub-BoardIndex.php) (http://www.simplemachines.org/community/index.php?topic=118299.msg3717732#msg3717732) replacement
o Operations # 1 and # 2 (QueryString.php) (http://www.simplemachines.org/community/index.php?topic=118299.msg3718770#msg3718770) replacement.

I installed this mod and it works correctly now.  Sorry about the previous posting....

EDIT: Attachment removed and made the public download at the mod download page.
Title: Re: View Single Category
Post by: Steve on August 11, 2014, 09:03:15 PM
Well, it worked perfectly on my test board but not on my normal one. Obviously some mod is getting in the way. Will have to figure out which one.
Title: Re: View Single Category
Post by: dougiefresh on August 12, 2014, 01:53:40 PM
Well, it worked perfectly on my test board but not on my normal one. Obviously some mod is getting in the way. Will have to figure out which one.
I tested my copy of this mod with SMF 2.0.7 install with the 2.0.8 patch, along with the Sorted Package Manager Listing (http://custom.simplemachines.org/mods/index.php?mod=875) mod installed, as indicated in your picture 2 posts ago.  Installation went fine, no errors.  It appears to work correctly, so we can safely rule out the Sorted Package Manager Listing (http://custom.simplemachines.org/mods/index.php?mod=875) mod as a problem.

In other notes, this mod doesn't work with Simple Portal......  Can it be made to work with it?  Let's see......
Title: Re: View Single Category
Post by: Steve on August 12, 2014, 04:55:34 PM
This is the error I'm getting under the ./Sources/QueryString.php step:

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi60.tinypic.com%2F24nfp5j.jpg&hash=b20a1e25e1e6b5bf89ced55bdef3ac47)

What does that mean?
Title: Re: View Single Category
Post by: dougiefresh on August 12, 2014, 05:16:26 PM
Attach your Sources/QueryString.php file so I can see what is going on....  Note that this mod doesn't work with Simple Portal, so if you have it installed, I can't make it work for ya....  (yet)
Title: Re: View Single Category
Post by: Steve on August 12, 2014, 05:54:59 PM
I don't use Simple Portal but I do use Tiny Portal.

File attached that you asked for. :)
Title: Re: View Single Category
Post by: dougiefresh on August 12, 2014, 07:25:25 PM
It looks like your QueryString.php has this line instead:
Code: [Select]
board|topic|page|cat)=[^#"]+?)(#[^"]*?)?"~', 'sid_insert__preg_callback', $buffer);Mod expects this:
Code: [Select]
board|topic)=[^#"]+?)(#[^"]*?)?"~', 'sid_insert__preg_callback', $buffer);So, since it's different than what the mod expects, the op fails.....  You could probably change your copy of the mod to accommodate this....
Title: Re: View Single Category
Post by: Steve on August 12, 2014, 08:58:51 PM
Thanks. I'll have a look at this tomorrow. I'm over the 'mess around in admin' alcohol limit ... :P
Title: Re: View Single Category
Post by: Steve on August 13, 2014, 03:31:09 PM
I took a look at it and decided I'm not confident enough to muck about with the coding of the board so I'll just have to live without this. :(
Title: Re: View Single Category
Post by: Steve on August 16, 2014, 06:39:18 PM
Okay, I think I'm going to attempt this after reading the manual on installing mods that show errors during the testing portion.

As far as I can see, the only difference between what your mod expects:

Code: [Select]
board|topic)=[^#"]+?)(#[^"]*?)?"~', 'sid_insert__preg_callback', $buffer);
and what it wants to do is adding a c| at the beginning of that line, correct?

So if I add that c| to what my file has:

Code: [Select]
board|topic|page|cat)=[^#"]+?)(#[^"]*?)?"~', 'sid_insert__preg_callback', $buffer);
the mod should still work, right?
Title: Re: View Single Category
Post by: dougiefresh on August 17, 2014, 09:08:24 AM
That looks like it should work, yes.....  I haven't tried it.
Title: Re: View Single Category
Post by: Steve on August 17, 2014, 10:20:09 AM
I'll give it a whirl. :)
Title: Re: View Single Category
Post by: SleePy on August 24, 2014, 01:15:39 AM
Yes it adds that.  It was for SEF urls to be handled properly.
Title: Re: View Single Category
Post by: Steve on August 30, 2014, 10:25:00 AM
Just wanted to say that I tried the manual change I mentioned above and the mod works perfectly. Thank you for this! Not having this has been one of my very few gripes about SMF. :D
Title: Re: View Single Category
Post by: Arantor on August 30, 2014, 12:04:41 PM
I would love to know if Google penalises sites that use this for duplicate content.
Title: Re: View Single Category
Post by: dougiefresh on September 07, 2014, 02:46:29 PM
The mod download site for this mod stated anyone interested in developing this mod should contact SleePy.  I did so.  SleePy agreed to transfer the mod to me, under the condition that I keep it free to the public.  I agreed to this condition.  SleePy approved and has transferred the mod to me.  Just so that y'all know  ;D

The unofficial mod was branded v2.1.9b.  It's now become official as version 2.2.0.
Title: Re: View Single Category
Post by: Arantor on September 07, 2014, 02:47:29 PM
Sounds awesome. Thanks for keeping the dream alive :)
Title: Re: View Single Category
Post by: dougiefresh on September 17, 2014, 07:52:36 PM
First post and mod description updated, giving proper credit to SleePy for creation of this mod and stating that the mod was taken over by me.....  I apologize for any confusion the first post and mod description for v2.2 gave anybody.

UPDATE: I am working to make this mod compatible with SimplePortal....  It will involve some rewriting of the code to make it work, though.... 

I also need to comb through this thread to find the compatibility issues (what needs to be installed before what), that way I can update the mod description properly....  It's kinda a "slap-my-mod-description-format-on-this-mod-without-researching-everything-more"-kinda issue....  ::)  If anybody wants to help me with this, please feel free as I've worked 23 hours over 2 days (fun.... NOT!)

I would love to know if Google penalises sites that use this for duplicate content.
I'm gonna tackle that issue as well....  I know there's a way to do so, but off the top of my head, I can't remember....
Title: Re: View Single Category
Post by: dougiefresh on October 20, 2014, 10:00:50 AM
Uploaded v2.3 - October 20th, 2014
o Improved compatbility with TinyPortal at install time (SMF 2.0 only)
o Added compatibility with SimplePortal (SMF 2.0 only)

DO NOT INSTALL IF:
o In ./Themes/default/scripts/script.js, none of the operations are successful.  One should be successful....
o In Sources/QueryString.php, none of the three pairs of operations (1 and 2, 3 and 4, or 5 and 6) are successful.

Attach the affected file to this topic for further assistance installing this.


I've left the v2.2.0 version up on the mod download page in the event that anyone needs it.
Title: Re: View Single Category
Post by: beanflying on December 22, 2014, 01:34:13 AM
Just started playing with it on a Dream Portal based test site. Some quirks to overcome so will see how it goes :)

If anyone has any pointers on how to crunch the code and save some time would be great .
Title: Re: View Single Category
Post by: beanflying on December 23, 2014, 04:42:34 PM
Replying to myself sort of.

Installed the mod and with some playing this url works fine for displaying single categories with Dream Portal installed.

http://www.xyz.com/index.php?action=forum;c=1

Which is fine for setting links off the menus or DP pages but when you click the headers of the categories it breaks and goes to the front page. Partal fix for what I wanted to do but if possible would be nice to sort out the category headers. :)
Title: Re: View Single Category
Post by: dougiefresh on December 23, 2014, 05:15:17 PM
Lemme see what I can do to make this mod more compatible with Dream Portal....
Title: Re: View Single Category
Post by: grandinquisitor on January 14, 2015, 10:57:41 PM
Help would be greatly appreciated -- I upgraded my forum from SMF2.0.6 to SMF2.0.9 and now viewing the category page gives me this error:


You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ORDER BY b.board_order' at line 23
File: /var/www/____.com/forum/Sources/Subs-BoardIndex.php
Line: 120

Note: It appears that your database may require an upgrade. Your forum's files are currently at version SMF 2.0.9, while your database is at version 2.0. The above error might possibly go away if you execute the latest version of upgrade.php.

I have Single Category Mod v2.1.9.  I downloaded 2.2.0 but it shows as the older version, and I can't uninstall v2.1.9 because of problems with QueryString.

Any help would be greatly appreciated!  Let me know if I need to upload anything.
Title: Re: View Single Category
Post by: Arantor on January 14, 2015, 11:05:26 PM
I'd suggest: Uninstall the SMF patches back to 2.0.6. uninstall Single Category 2.1.9, reinstall SMF patches, install updated Single Category mod.
Title: Re: View Single Category
Post by: grandinquisitor on January 15, 2015, 02:11:32 PM
Oddly I can't uninstall SMF 2.0.8.  It returns an error in Memberlist.php which I don't think I've ever modified. 
Title: Re: View Single Category
Post by: Arantor on January 15, 2015, 02:15:51 PM
Which error fails? If you expand the list of changes, it will tell you how many changes, and then you can click on the little post icon to see what has actually failed.

I suspect it is failing on the test where it's trying to add 'serach_fields' which is a typo in some 2.0.8 installs but was fixed in later copies of 2.0.8 and 2.0.9 would definitely have fixed it regardless. It's probably OK to ignore that one, but if you're not sure, you can always ignore it for now, do the rest of the stuff outlined and then we'll look at whether that one file needs any more work doing to it (but after 2.0.9 is reinstalled, I doubt it)
Title: Re: View Single Category
Post by: grandinquisitor on January 16, 2015, 12:01:31 PM
Yep, that's it. 

Unfortunately now I have more problems uninstalling 2.0.7.  Two of the fails are on copyright notices, which is weird but not fatal.  Another fail is on Subs-Post.php, where it can't find
Code: [Select]
if (allowedTo('admin_forum'))
{
static $htmlfunc = null;
if ($htmlfunc === null)
$htmlfunc = create_function('$m', 'return \'[html]\' . strtr(un_htmlspecialchars("$m[1]"), array("\n" => \'&#13;\', \'  \' => \' &#32;\', \'[\' => \'&#91;\', \']\' => \'&#93;\')) . \'[/html]\';');
$parts[$i] = preg_replace_callback('~\[html\](.+?)\[/html\]~is', $htmlfunc, $parts[$i]);
}

In the meantime I still can't uninstall Single Category v 2.1.9 because of errors in QueryString.
Title: Re: View Single Category
Post by: Arantor on January 16, 2015, 12:08:59 PM
It sounds like you have oddly old versions of things because there were several releases of several of the patches due to last minute things :(

So, at this point, can you reinstall back to 2.0.9? Let's at least get back to a point where we know where we are for sure.
Title: Re: View Single Category
Post by: grandinquisitor on January 16, 2015, 12:23:35 PM
Yeah I put off upgrading for a long time because I couldn't get it working, not realizing that I was a victim of the infinite loop fopen bug.  Back to 2.0.9 now.  Uninstalling Single Category 2.1.9 fails on:


Code: (Find) [Select]

Code: [Select]
oOption.value = aBoardsAndCategories[i].isCategory ? '?action=forumc=' + aBoardsAndCategories[i].id : '?board=' + aBoardsAndCategories[i].id + '.0';
Code: (Replace) [Select]

Code: [Select]
oOption.value = aBoardsAndCategories[i].isCategory ? '#c' + aBoardsAndCategories[i].id : '?board=' + aBoardsAndCategories[i].id + '.0';
It also has a second fail that's completely blank, which puzzles me.  That is to say, it just says "Code: (Find) [Select]" and then a blank box underneath, and "Code: (Replace) [Select]" with another blank box underneath.
Title: Re: View Single Category
Post by: Arantor on January 16, 2015, 12:27:11 PM
That particular edit is a bug in the code, it's looking for something slightly different to what it actually put there before.

If you look in the file it indicates for the first part of it:
Code: [Select]
oOption.value = aBoardsAndCategories[i].isCategory
Then replace that entire line with the line indicated, that would fix that one issue.

The other one is a bit weird. The old version appears to have been removed so I can't take a look at what's wrong with it :(
Title: Re: View Single Category
Post by: grandinquisitor on January 16, 2015, 12:46:13 PM
In the 2.1.9 package, the relevant portion for QueryString.php reads:

Code: [Select]
<file name="$sourcedir/QueryString.php">
<operation>
<search position="replace"><![CDATA[board|topic)=[^#"]+?)(#[^"]*?)?"/e', "'\"' . \$scripturl . '/' . strtr('\$1', '&;=', '//,') . '.html?' . SID . '\$2\"'", $buffer);
]]></search>
<add><![CDATA[c|board|topic)=[^#"]+?)(#[^"]*?)?"/e', "'\"' . \$scripturl . '/' . strtr('\$1', '&;=', '//,') . '.html?' . SID . '\$2\"'", $buffer);
]]></add>
</operation>
<operation>
<search position="replace"><![CDATA[board|topic)=[^#"]+?)(#[^"]*?)?"/e', "'\"' . \$scripturl . '/' . strtr('\$1', '&;=', '//,') . '.html\$2\"'", $buffer);
]]></search>
<add><![CDATA[c|board|topic)=[^#"]+?)(#[^"]*?)?"/e', "'\"' . \$scripturl . '/' . strtr('\$1', '&;=', '//,') . '.html\$2\"'", $buffer);
]]></add>
</operation>
</file>
Title: Re: View Single Category
Post by: grandinquisitor on January 17, 2015, 03:41:20 PM
I've realized something odd.  The oOption.value line is actually in script.js, not QueryString.php.  v2.1.9 should have had the two changes listed above uninstalled, but I confess I'm having difficulty parsing it to figure out what exactly I'm supposed to be changing.  This is what I see in QueryString.php:

   
Code: [Select]
// This should work even in 4.2.x, just not CGI without cgi.fix_pathinfo.
if (!empty($modSettings['queryless_urls']) && (!$context['server']['is_cgi'] || @ini_get('cgi.fix_pathinfo') == 1 || @get_cfg_var('cgi.fix_pathinfo') == 1) && ($context['server']['is_apache'] || $context['server']['is_lighttpd']))
{
// Let's do something special for session ids!
if (defined('SID') && SID != '')
$buffer = preg_replace_callback('~"' . preg_quote($scripturl, '/') . '\?(?:' . SID . '(?:;|&|&amp;))((?:c|board|topic)=[^#"]+?)(#[^"]*?)?"~', 'sid_insert__preg_callback', $buffer);
else
$buffer = preg_replace_callback('~"' . preg_quote($scripturl, '/') . '\?((?:c|board|topic)=[^#"]+?)(#[^"]*?)?"~', 'pathinfo_insert__preg_callback', $buffer);
}

I hope this makes sense -- I also attached the v2.1.9 package.
Title: Re: View Single Category
Post by: dougiefresh on April 10, 2015, 07:58:34 PM
Uploaded v2.4- April 10th, 2015
o Updated for SMF 2.1 Beta 1
o Simplified the 2 operations in QueryString.php.
Title: Re: View Single Category
Post by: dougiefresh on August 29, 2015, 10:06:49 AM
Uploaded v2.5 - August 29th, 2015
o Removed support for SMF 2.1 Beta 1
o Added support for SMF 2.1 Beta 2
Title: Re: View Single Category
Post by: Diego Andrés on September 20, 2015, 11:20:07 PM
Hi, I believe there's some kind of issues while using this mod and Alias Boards.
When I access a category its working normal but, there's a blank category below with an empty board (empty of name and pretty much everything) and it's gone when I removed all the alias.

Thought you'll now better where should I modify to get this fixed.
Title: Re: View Single Category
Post by: dougiefresh on September 21, 2015, 01:08:54 PM
Hi, I believe there's some kind of issues while using this mod and Alias Boards.
When I access a category its working normal but, there's a blank category below with an empty board (empty of name and pretty much everything) and it's gone when I removed all the alias.
Because I read the Alias Boards mod thread long long ago, I happen to know that the way the Alias Boards mod is implemented is to blame for this particular nasty bug.....  What happens when the Alias Boards mod is installed is all board information is gathered for the Board Index.  When it is displayed, we can easily display the aliased boards on the Board Index because we have the information already pulled to do so.  When you throw in the Single Category mod in the mix, all of a sudden, the aliased boards don't work.  This is because the query was changed to ONLY pull the boards from the specified category, making any aliases worthless because all the board information isn't loaded....

In all likelihood, the changes will somehow need to be made in the Alias Boards mod so that the information is available within a single category.  That mod has been marked for a revamp to correct issues such as board ordering with aliases mixed in....  I seriously doubt any changes will need to be made in the Single Category mod.
Title: Re: View Single Category
Post by: Diego Andrés on September 21, 2015, 03:20:08 PM
Great, I'm moving my eyes into that support topic then.

Thank you.
Title: Re: View Single Category
Post by: dougiefresh on July 06, 2017, 09:07:25 AM
Uploaded v2.6 - July 5th, 2017
o Added support for SMF 2.1 Beta 3.
o Removed support for SMF 2.1 Beta 2, as well as SMF 2.0.8 and older.
Title: Re: View Single Category
Post by: confuseamuse on August 02, 2017, 04:56:13 PM
I have a problem with this mod and it occurs when you click on a link in the path whilst in a topic (seen above as such):
(https://i.imgur.com/SI5ybGY.png)

If you click on the category name whilst in a topic, it directs you to a page with nothing below the path. The url also reads:

Code: [Select]
forum.com/index.php?c=7Instead of:
Code: [Select]
forum.com/index.php?action=forum;c=1
How would I correct this error?
Title: Re: View Single Category
Post by: Arantor on August 02, 2017, 05:21:20 PM
So there's a conflict between whatever portal mod you use and this mod, and I'm not sure what the correct URL should be since intercepting process flow that early on really isn't a good idea for mod compatibility.

So, let's start with that, which portal mod do you use?
Title: Re: View Single Category
Post by: confuseamuse on August 02, 2017, 07:36:21 PM
So there's a conflict between whatever portal mod you use and this mod, and I'm not sure what the correct URL should be since intercepting process flow that early on really isn't a good idea for mod compatibility.

So, let's start with that, which portal mod do you use?

Now that you've said this, it might be the PrettyUrls mods that's causing the conflict.

I also use SimplePortal.
Title: Re: View Single Category
Post by: dougiefresh on August 02, 2017, 07:38:31 PM
Let me look into this bug report....
Title: Re: View Single Category
Post by: brynn on September 21, 2017, 11:43:15 PM
Hi Friends,  (sorry, longish)
I've just run into the last issue reported here, too.  I think I've seen those kind of links referred to as "breadcrumbs", although I tend to think of it more as a link-path.

Anyway, for example, you've just finished reading a topic, and you want to go back to the same category (for whatever reason).  Find the link-path/breadcrumbs, and click on the category.

For me, it actually opens a page.  Every single category opens the same URL (https://forum.inkscapecommunity.com/index.php?c=3).  I don't know why that URL opens this page, because that's not the URL for that page.  The page it opens technically is an article in the Tiny Portal mod.  But it's real URL is either https://forum.inkscapecommunity.com/index.php, or https://forum.inkscapecommunity.com/index.php?page=28.  I have no idea how "c=3" got to be on the end, or why the whole URL opens that page.

SMF 2.0.14
Tiny Portal 1.2 (need to upgrade)
View Single Category 2.4 (need to upgrade)

I can list all our mods, if necessary (around 45).  I made a topic which you can use for testing:  https://forum.inkscapecommunity.com/index.php?topic=769.0  I don't think you'll need to register.

Oh, this is interesting!  I have another SMF forum which uses Simple Portal.  (Let's call the first one IC for Inkscape Community, and let's call this one ICD Inkscape for Cutting Design.)  https://www.inkscapecuttingdesign.com/smf/index.php

In ICD, clicking the category, no matter where you click the link (from the index page, or link-path in an open topic) it simply uses something like an html anchor.  Instead of opening a new portal page which displays only the category (as it does in IC) it simply changes which part of the index page you're looking at.  It puts whatever category you clicked at the top.  But if you scroll, you can still get to the rest of the index page.  In IC, the mod actually makes a new portal page, with only that category on it - even if you scroll, only that category is on the page.

I don't know, maybe that anchor-like behavior is a fallback or something, if a particular theme isn't compatible?  But I thought worth a mention.

The main issue is in IC where the link does not open the category (in any way).

Sort of off topic:
If it can be explained in a relatively simple way, could someone explain why this issue is not a bug?  Why is clicking on a category, not opening a category, not a bug?  I mean, I certainly appreciate that we have this mod to fix it.  But it seems to me like the forum's code should be fixed instead. 

I don't remember what clicking on the category does (since I've had this mod for a while).  But I don't know what could be considered more appropriate than clicking on a category  to open that category.  This really is the only complaint I've ever had about SMF (compared to other forum software).
End off topic

Anyway, let me know if I can help with testing and stuff.  Or if you need any more info.
Title: Re: View Single Category
Post by: dougiefresh on March 05, 2018, 10:46:47 AM
Uploaded v2.7 - March 5th, 2018
o Changed operations in Sources/QueryString.php for better compatibility.
Title: Re: View Single Category
Post by: Rock Lee on March 05, 2018, 12:36:00 PM
I do not fully understand how it works ... but I'm going to try it if I catch it :P very good @dougiefresh thanks for sharing ;D.


Regards!
Title: Re: View Single Category
Post by: dougiefresh on November 09, 2018, 12:16:38 PM
Uploaded v2.8 - November 9th, 2018
o No functionality change.
o Updated documentation to point to new website.
Title: Re: View Single Category
Post by: dougiefresh on June 19, 2019, 07:42:04 PM
Uploaded v2.9 - May 22, 2019
o Added support for SMF 2.1 RC2.
o Removed support for SMF 2.1 Beta 3.