Hi Guys,
I am considering changing my whole forum look and using blocks etc to make it possible but I am just wondering how to make some things work... basically for example I want 2 blocks side by side.. the left one will show the forum categories and when click the topics will show in the right block.. and when a topic is click in the right box it will then show the post... is this possible? Hopefully I have explained it well enough so you can understand what I am.. and I have also included a piccie of the type of look and an example I am going for as well..
I am sick of the whole traditional look where you have all the forums listed and want to spice it up a bit for my site... I have the left side (listing the categories done) but its just getting the information to show in the right block which is throwing me off a bit..
Should also add I am using smf 1.1.10 and tp v1.0 beta 4
Any help or advice would be greatly appreciated! :)
I think this would require some custom coding, but it is an interesting idea. Someone with code experience and abilities will need to look at the request.
In it's basic form, you could hand code a block to show all the board names/links in a left hand block, which would give you the layout you'd like.
That way, the topic listings, and topics would still show as normal in the centre.
Only thing would be, how you would prevent the board listing (i.e. the normal forum homepage) from appearing in the centre.
thanks MC had thought of that but it really defeats the point of redesigning it
Renegd98, thanks for the response. had a feeling it would been a coding job :)
if someone could give me an idea or a starting point I would be happy to give it a whirl!
so how about a block listing board names on the left... either hand coded (tedious?).. or a script to pull all the names & links.
surely then the links only need to contain /index.php?board=2.0 with a link for each relevant board ?
It depends on if you want to make the board index bit into a block or not.
If you make it a block, it means you can control where you want to place it better.
If not, it means you'll have to customize the code more.
The hard coded method I mentioned above, is the simplest way I can think of doing it.
If you want to automate it, then you'll need to look at boardindex.template.php, to see how it generates the board index, and then modify/write code to replicate it's function, but in the format you'd like.
If you don't want to use a block, then you'll need to modify the index.template.php, so it calls/inserts code to add the board index links to the relevant pages.
I have already created a block code that will list the boards and sub-boards as a menu.
http://www.tinyportal.net/index.php/topic,18318.0.html
But a few questions come to mind when I'm thinking about this Bec. Do you want the menu and the recent topics shown in separate blocks? If they were to be put in the same block, but made to "appear" as two different blocks would that be ok? When you say you want the post to appear, do you want the post to appear outside of the forum? Or do you want it to take the person to the post in the forum? Not sure I'll have time for this, but I just wanted to get some clarification. Would be cool to see it all work with some ajax without refreshing the page. :D
Hi IchBin, thanks for taking the time to check this out for me :)
I would prefer to have the menu and the most recent topics in separate blocks.. but in saying that if they "appeared" to be separate that would pretty much appear to be the same so all would be cool with that.
Ok basically I want to get remove the forum altogether and have the menu links on the left side, in the other block (or whatever it needs to be) i would like the main screen to be the most recent topics... and then when each different category is clicked for it to show the posts within that forum. I am hoping that makes sense... if you check out http://www.bridesdiary.com.au/myWedding/latestPosts.aspx?p=2 it is pretty much how they have their forum setup and is the best real example i can give you of what i mean... the most recent topics is the main screen and then you can click on each different category to view the posts within that section, when a topic is clicked it takes you directly to the post.
It would be awesome if something could be put together and I think it would be an invaluable source to many people cause we can keep the smf software we love but tweak the look a little so its not the run of the mill forum which is what i ideally want. I am no expert with coding but I am going to try and read up on how we can do it, not sure how far Ill get but interested to learn! Worst case if it cant be done, Ill create a new article and link the categories up to it similar to how I did my gallery pages..
Thanks again for the input guys, I appreciate it!
I have some code that is working similar to what you're describing. It uses ajax so that the page doesn't refresh. So when you click each board in a category it loads the most recent topics. So when you click on one of the topics, do you want it to take you into the forum so you are actually viewing the post inside the topic? I sure hope so. lol
yup sounds perfect IchBin! only thing when you click on each category does it only show you the recent topics in that category? or does it still show you the other older topics as well?
Well, it can show as many recent topics as you want. But it doesn't do multiple pages of topics. You can have it display 20 or 50. It's a setting I've put into the code that you can choose. If you're ok with that, let me know and I'll try to put some finish touches on it tomorrow.
hey IchBin, sounds pretty good I can always link up to all forum posts or something in another area... look forward to seeing what you have come up with and thanks again for doing this! appreciate it heaps!! :)
Ok, here's a version I think is working. I haven't tested it on a site with sub-boards yet, so let me know how that goes. I'm sure we'll be tweaking this to make it the way you want. For now, I've made it look good in the default theme. There are a couple of options at the top of the code. One is to set a default board to load topics from when a person hits the page for the first time. The other setting is to limit how many recent topics you want to display on the page. It must be in a PHP type block. You can simply make the changes to the file, then upload it to the root of your SMF forum and call it in a block like this:
include('itch_recent.php');
If you don't want to do that, you should be able to copy/paste the code into a block and save it. I should also note that there is some CSS in the code that you can play with to change the display.
Let me know what you think or if you have any problems.
Thanks IchBin, will give it a go tomorrow and let you know how things go! Thanks again for your help with this :)
Actually, I take that back. I don't think you'll be able to paste the code into a block because of the way the Ajax works. You'll need to upload the file to make it work properly.
Hello, IchBin.
I have tried that but this is what I get...
TP 0.9 . 8 , 1.1.10
Ah the menu breaks out of the block. I guess I need to test it on a board where there are enough boards to do that. If you select a board that has more topics, and the recent topics table is taller, does it push the block down far enough to make it look better?
At the left it shows all the categories and boards in forum. At the right it shows only two topics despite the fact that there are more that 100 in this board...
The only things I modified was in this part of the code:
/************* CONFIGURATION OPTIONS **************/
// Set the number of recent topics to display (default is 10)
$limit = 10;
// Default display of recent topics. Choose board to load by default when no board has been selected.
$theboard = (int) 18;
/************ END CONFIGURATION OPTIONS************/And in error log it gives this error:
Quote8: Undefined variable: my
ἈÃÂÇεá¿â€"ο: /home/site/forum/SMF/itch_recent.php
Line: 234
Ah yes, I have fixed the my error. I changed variable names and didn't change my. :D
Fixed in the post above where I attached the file. However, the topics returned I'll have to play with for a bit. I don't quite understand how the query only grabs certain messages by activity just yet. But will post back when I have a fix.
Hi Ichbin,
I gave it a go and while it has great potential its not really what I am after... appearance wise it worked perfect for me only problem I had was if a forum had not been posted in recently, when clicked it would give an error message "Warning: Invalid argument supplied for foreach() in /home/buctai8/public_html/itch_recent.php on line 224"
I have managed to have a play around and have come up with something which is pretty close to what I want... instead of having the normal forum page I plan on having the landing page as the most recent topics and having a menu linked up to the side (as per the attached picture) looks pretty great so Im pretty excited with it!
Thanks heaps for taking the time trying to do this, it really is appreciated!!