Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
themes-topic
In forumview, show the "sub forums" below the parent forum.
Avatar
tyeung
Member
Free Members
sp_UserOfflineSmall Offline
Dec 14, 2011 - 7:27 pm

Hey guys!   Things are coming along nicely with v5 =)

 

Any way to modify the spforumview file so that the Subforums appear below the main "parent" forum header?  In pic below, you can see my technical forum "intro" actually appears below the subforums contained within.  I tried playing with the spforumview file and moving some stuff around but ended up breaking it so better to leave it to the experts 😉

thanks again guys.  (disregard the blue text in the pic, it was my notes but it's kinda small to read!)

 

reverseforumview.jpgImage Enlarger

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Dec 14, 2011 - 7:57 pm

so if I understand... you just want to list the topics in the forum first... then underneath, the subforums?

If so, look at the template... you will see two distinct sections...  just change the order... that is.. move:

            if (sp_has_subforums()) :

that whole 'if' code section to be under the section that starts with:

            sp_SectionStart('tagClass=spForumViewSection', 'forumHeader');

voila...

Avatar
Christian Pagan
Florida
Member
Free Members
sp_UserOfflineSmall Offline
May 21, 2012 - 12:33 pm

Mr Papa said
so if I understand... you just want to list the topics in the forum first... then underneath, the subforums?

If so, look at the template... you will see two distinct sections...  just change the order... that is.. move:

            if (sp_has_subforums()) :

that whole 'if' code section to be under the section that starts with:

            sp_SectionStart('tagClass=spForumViewSection', 'forumHeader');

voila...

I am a little lost on this, I have been trying to do this with no results I keep getting errors. Please let me know what file to edit and where exactly yo put this if command, because I cannot get it to work.

http://www.tncnewscentral.com/forum

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
May 21, 2012 - 3:09 pm

Steve didn't say you had to enter the if statement - he said you needed to move that block of code.

It's the spForumView.php theme template of your selected SP theme - as you identified above.

The sub-forum section starts with that 'if' statement - or the comment before it: "# Are there sub forums to display". It ends with the comment line '# End of subforum section'.

Just move that whole block down to where you want it - which is probably immediately above the 'editor' section of code which you can also identify by the comment that starts it.

As always we recommend that you create your own SP theme so that any customisation is not lost during a future update. (http://codex.simple-press.com/.....g-a-theme/)

andy-signature.png
YELLOW
SWORDFISH
Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626