![]() |
Users posts
This small mod will tell you some small stats about where a member is posting : in which forums and what it represents against his total number of messages (see screenshot below. sorry it's a french screenshot ).
It respects your forums ordering and groups them by category, with a total by category. Php code to place in the "modcp" dir, filename "usermess.php" : PHP Code:
PHP Code:
Last changes : v1.2
v1.1
|
thx
looks fine the only thing i would change is on the picture because i dont know how to say it this i changed but the sum isnt right PHP Code:
PHP Code:
|
then we change the hook into admin_index_navigation and sim sala bim its here*g*
sorry my changes wount work so don't do the change*g* |
Quote:
direkt wird dort nichts eingebunden ;) die cpnav_vbulletin greifen wir NICHT AN ;) sondern du erstellst eine cpnav_mike.xml im includes/xml verzeichniss und schreiben folgendes rein Code:
<navgroups master="false"> |
Two main reasons for putting it in modcp :
Quote:
PHP Code:
|
hi becafuel,
nice add on but i have two suggestions: - he doesn't sort the forum the right way. - i would show forum without post too. you could easier compare and find anything when every forum is always on his place. hurik |
I have modified the code in the first post to accomodate with suggestions from feedback.
What do you think of it, now ? Quote:
Quote:
|
Quote:
Quote:
and look at: http://www.portablegaming.de/forumdisplay.php?f=3 and the categorys are not soreted right tot. gameboy advance should be the 3th category but it is the first. http://www.portablegaming.de |
because the order
then someone must build the displayorder into the query ;) i think that will not be enought... |
In fact, I am actually ordering by forumid, which is not the real display order (except on my forum, hence the confusion ;) )
I am working on it but it will take a little longer to code because it's not only a matter of query... |
Great , some one put a few wonderful php code the other bring it back with more nice ideas and the 3rd from some place on this planet collect and correct it to be a wonder full hack .
Thanks a lot guys ¤¥installed¥¤ |
very good addon thanks for posting, trying out right now :)
|
Quote:
|
That's what I was planning to do ;) I'm not willing to re-invent the wheel each time...
|
hehe :)
but nice method for the menu that i don't know until i see it here |
But. Can you place the code into one xml product? I dont know how to modified PHP.
|
I dont know how to install it?
where to place this code? Module to create using "mod_index_navigation" hook (choose a name you like for this module) : PHP Code: construct_nav_spacer(); construct_nav_option('Number of messages', 'usermess.php?'); construct_nav_group('Menu title'); I hope you will enjoy this. It's not a great mod, but I think it can be useful or at least handy, though. |
In the admin cp, plugin system, add new plugin. You then choose a title for this plugin (the name that you like, it's on your own) and choose mod_index_navigation as hook. Then you place the code in the "Plugin PHP Code" section.
Do not forget to activate the plugin by checking the radio button under this text area ;) Really, it's simple to do. Easier than .xml file, at least for such a small add-on. XML files are good for bigger projects or admin-only tools, I think. I'm still currently working on the two last points, but the end of the year is hard for me and my work :( I do not have much time for this. |
one question
why the menucode is: construct_nav_spacer(); construct_nav_option('Number of messages', 'usermess.php?'); construct_nav_group('Menu title'); 1. the links 2. the "menu" or doesnt it matter? |
Quote:
|
Quote:
Btw, I will help you as much as I can, of course. Quote:
|
New version v1.2
Most noticeable change : forums are now correctly ordered. That is : same order than your layout. It also shows forum with 0 (zero) messages. A new variable that you should modify in the above source code : $phrase_percentage. This is the translation for french "Par rapport au total", which could be "Compared to total number of messages" in english. As I didn't want to create a vbphrase only for this one, I've kept it in a variable. Next version change will add the option to include or not forum with no messages. I hope you find this mod useful ;) |
How can I Upgrade this Mod?
|
Quote:
|
Quote:
and is it faster then the xml file in the includes/xml ? |
I don't know why it is done this way.
For the second question, it's not a matter of speed, IMHO. XML method requires vbphrases to be created for your options & menu title in admincp, not with modcp menus. Although you can work without vbphrases in admincp, options and titles will be displayed like *[your_text]*, meaning you missed some vbphrases. See attached screenshot. This is one of the two reasons why I've put this mod in the modcp section. I didn't want to play with xml and phrases for only one option in a menu. In a way, we can say it's faster to code for me, but code is not faster either way ;) |
no it doesnt need phrases
<text>your link</text> works too ;) |
Damn ! You're right ! Why the hell did I focus on <phrase>some text</phrase> ?!
Thx a lot ;) |
Then we will talk about this via PMs ;)
|
I like this, although I put mine in ACP
/me installs |
How to modify this code for users? (i wan't them also see their statistic)...
Can somebody give me full code or "hack" file? |
You can put the code in the root directory of your forum and then put a link somewhere (i.e. in navbar) to this file.
|
Very handy add-on really.
Is there any chance to do it also for reputation points? To see where the user got his rep. points? Event better would be to group forums by topic for this purpose... Thank you!!! |
ok. thank you. i'll try it.
|
I've correctly installed it but when i click on the menu in the MOD CP I get this:
Code:
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in ------------/public_html/forum/modcp/usermess.php on line 2 |
I installed. But where does this show up at? I can't find it anywhere. I don't use the default style however.
|
it is in the acp!
|
Oh. I thought this would be on the user profile or something so everyone could see it instead of just the admins. Anyway to do this?
|
Quote:
|
Quote:
If you want it in the ACP, then you should create an XML file for this. Quote:
|
All times are GMT. The time now is 04:53 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|