1 (edited by keeshii 2015-11-02 13:05)

Topic: [Extension] om_subforums 0.0.3

Hi,
I have finished working on extension, which adds subforums functionality. I was relaying on extension made by putnik - he does a great work (respect), but unfortunately it wasn't working properly on my forum 1.4.2 - and I was afraid that it will damage my database. I have downloaded also the extension made by prokop, but when I saw his changes and his code my eyes started to cry hmm In the end I have decided to make my own extension, and I am presenting it to you:

om_subforums 0.0.4 (current): om_subforums-0.0.4.zip


The file structure I have left the same as in putnik extension - it was clean, fast, just good - everything else is I have changed. I have made an assuption, that only one level of nesting is allowed - this let me make much simplier, less complicated extension than putnik. I have also tested my extension with many scenarios - fe. changing category of parent forum, changing parent, deleting parent forum, removing category, etc.

Maybe someone will find this extension useful.

Screenshots:
http://dev.poldrag.katowice.pl/distfile … forum0.png
http://dev.poldrag.katowice.pl/distfile … forum1.png
http://dev.poldrag.katowice.pl/distfile … forum2.png
http://dev.poldrag.katowice.pl/distfile … forum3.png


change log:

v.0.0.4 - 2014-09-16
- support for php 5.5 and postgres

v.0.0.3
- support for new posts notifications
- more hooks

v.0.0.2
- source code reorganizetion (functions.php instead subforums.class.php)
- fix for quickjump forum list

v.0.0.1
- assigning parent forum
- display mode (show on main page, show above topics)

regards,
keeshii

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

2

Re: [Extension] om_subforums 0.0.3

Oh, really thanks for this extension. I was REALLY looking for subforums. Great work, mój rodaku :-).

Re: [Extension] om_subforums 0.0.3

(Y)

sorry my BAD english T___T
Have a nice day >.<
(^____^)v

Re: [Extension] om_subforums 0.0.3

keeshii do not cry smile)

Re: [Extension] om_subforums 0.0.3

Sorry, prokop. I didn't want to offend you. It wasn't that bad afterall.

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

Re: [Extension] om_subforums 0.0.3

I have this error

Fatal error: Cannot redeclare class subforums in /home/pspirata/domains/ps4pirata.com/public_html/extensions/om_subforums/subforums.class.php on line 6

Please help me !!!

7 (edited by keeshii 2013-10-02 20:38)

Re: [Extension] om_subforums 0.0.3

Probably you have activated both: om_subforums and extension from putnik/prokop. I will change name of this class today evening.

EDIT: ok, i have commited changes to my repository => no more problems as above.

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

Re: [Extension] om_subforums 0.0.3

The extension works great, and installed with no problem. The issue I do have though is that although all the sub sections are listed in the parent on the board index, when I open up the parent, I don't have the subforums sections listed like in the forums2.png image posted here.

http://dev.poldrag.katowice.pl/distfile … forum2.png

Any idea what I can do to fix that?

9

Re: [Extension] om_subforums 0.0.3

It regards the configuration. Look in settings -> setup or features. I don't remember good.

Re: [Extension] om_subforums 0.0.3

Yes, that worked-thank you.

For anyone else that has the same issue, it is in settings -> features -> Show subforums mode

Thanks again for the help.

Re: [Extension] om_subforums 0.0.3

What other extensions have you installed in your forum.

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

Re: [Extension] om_subforums 0.0.3

om_subforums is not compatybile with the extension: "last_topic_title_on_forum_index", not yet smile I have analysed the problem, but it is quite complex -I will have to do some changes in both extensions, not only in om_subforums. I will look at them closer on weekend.

Problematic cases:
- user is creating a new topic in subforum, it should be visible on index page
- fetching last topics of the subforums.

You will have to disable one of these extensions, until the patch is released.

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

Re: [Extension] om_subforums 0.0.3

nice Extension  i want it 
thanks

Re: [Extension] om_subforums 0.0.3

One more thing: if someone post new thread in sub-forum , forum and sub-forum indicator showing there is no new posts. But when you enter sub-forum topic looks like unread. Please fix it if you can. Thanks a lot smile

Re: [Extension] om_subforums 0.0.3

Newuser12 wrote:

One more thing: if someone post new thread in sub-forum , forum and sub-forum indicator showing there is no new posts. But when you enter sub-forum topic looks like unread. Please fix it if you can. Thanks a lot smile

Anyone?

16 (edited by keeshii 2013-12-25 12:43)

Re: [Extension] om_subforums 0.0.3

Newuser12 wrote:
Newuser12 wrote:

One more thing: if someone post new thread in sub-forum , forum and sub-forum indicator showing there is no new posts. But when you enter sub-forum topic looks like unread. Please fix it if you can. Thanks a lot smile

Anyone?

Done.

Steps to update:
1. delete old om_subforums from extensions folder
2. copy new om_subforums to extension folder
3. go to http://your_forum/admin (index won't work, but admin will)
4. go to extensions panel, and press upgrade


last_topic_title_on_forum_index
I have also added some new hooks, and now om_subforums may be used together with the extension "last_topic_title_on_forum_index", but some changes in its manifest are needed:

diff -urN last_topic_title_on_forum_index/manifest.xml last_topic_title_on_forum_index_2/manifest.xml
--- last_topic_title_on_forum_index/manifest.xml    2011-10-29 21:55:19.000000000 +0200
+++ last_topic_title_on_forum_index_2/manifest.xml    2013-12-25 12:33:39.368279835 +0100
@@ -167,12 +167,17 @@
         ]]></hook>
 
 
-        <hook id="in_qr_get_cats_and_forums"><![CDATA[
+        <hook id="om_subforums_fn_update_forum_info_last_post"><![CDATA[
+            $cur_forum['last_post_subject'] = $cur_subforum['last_post_subject'];
+        ]]></hook>
+
+
+        <hook id="in_qr_get_cats_and_forums, om_subforums_qr_get_cats_and_forums"><![CDATA[
             $query['SELECT'] .=', f.last_post_subject';
         ]]></hook>
 
 
-        <hook id="in_normal_row_pre_display"><![CDATA[
+        <hook id="in_normal_row_pre_display, om_subforums_normal_row_pre_display"><![CDATA[
             $last_topic_title_max_len = isset($forum_config['o_max_last_topic_title_length']) ? intval($forum_config['o_max_last_topic_title_length'], 10) : 0;
             $last_topic_title_mode = isset($forum_config['o_last_topic_title_mode']) ? intval($forum_config['o_last_topic_title_mode'], 10) : 1;
             $last_topic_title = $cur_forum['last_post_subject'];

Or download patched extension from here: last_topic_title_on_forum_index_patched.zip

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

Re: [Extension] om_subforums 0.0.3

thxx guru big_smile pro extension wink

sorry my BAD english T___T
Have a nice day >.<
(^____^)v

Re: [Extension] om_subforums 0.0.3

Thank you very much. Great update. HandShake.

Re: [Extension] om_subforums 0.0.3

What if you have the subforums package by 2008-2012, Sergey "putnik" Leschina
All rights reserved.

Can you simply disable that and go with this updated version?

My fear of deleting it is that I will lose any topics or threads that my users frequent.

Re: [Extension] om_subforums 0.0.3

There won't be any problems, just install the latest version of this extension. As you said - disable the old extension, install the new one:

1. Disable putnik's extension (subforums)
2. Install om_subforums 0.0.3 (not 0.0.1, not 0.0.2 - it must be the latest version!)
3. Unfortunately you will have to set the forum's hierarchy from the scratch
4. If everything is working, uninstall putnik's extension.

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

Re: [Extension] om_subforums 0.0.3

Thank you keeshi, I appreciate that.

I sent you an email earlier in the week regarding a different matter.

I'll be watching for your response.

Re: [Extension] om_subforums 0.0.3

Undefined cat_count in vf.inc.php line 72
<?php echo $forum_page['cat_count'] ?>

Re: [Extension] om_subforums 0.0.3

Newuser12 wrote:

Undefined cat_count in vf.inc.php line 72
<?php echo $forum_page['cat_count'] ?>

It was just a notice, corrected.

If you want to contact me quickly - send e-mail, not PM.
<?php $t='<?php $t=%c%s%c; printf($t,39,$t,39,10);%c'; printf($t,39,$t,39,10);

Re: [Extension] om_subforums 0.0.3

is anybody here alive? Have someone tested this good extension on punBB 1.4.4?

25 (edited by Xuantia 2016-03-10 20:05)

Re: [Extension] om_subforums 0.0.3

edgarsedov wrote:

is anybody here alive? Have someone tested this good extension on punBB 1.4.4?

I can confirm that it seems to work fine on PunBB 1.4.4 without any errors. I tested on my localhost machine using XAMPP for Windows 5.5.30. smile

EDIT: As as side note I also used the latest version of this extension which is 0.0.4