I've seen this one before on some YaBBSE boards. In users profiles and in posts it would display the members order of registration. For example the Administrator would be member #1, and the person who registered next would be #2 and so on, hope that makes sense.
It looked like this
Scott
Member
(Insignia of some kind)
Posts: 1066
Member Number: 20
This is also here but the member number isin't displayed in the post screen, if you want this feature added to your forum speacially, I would be glad to help you out. :)
Just PM me. :)
Quote from: Lamper on May 14, 2004, 03:32:39 PM
This is also here but the member number isin't displayed in the post screen, if you want this feature added to your forum speacially, I would be glad to help you out. :)
Just PM me. :)
Thanks I'd appreciate it. :)
you'd just have to modify Load.php to add the member number to the $context array and use it in the display template... it shouldn't be too hard.. heck, it may already be in $context lol, haven't checked though
Profile:
In Themes/default/Profile.template.php
Search for:
<tr>
<td><b>', $txt[86], ': </b></td>
<td>', $context['member']['posts'], ' (', $context['member']['posts_per_day'], ' ', $txt['posts_per_day'], ')</td>
</tr><tr>
Add after:
<td><b>Member Number: </b></td>
<td>', $context['member']['id'], '</td>
</tr><tr>
Posts:
In Themes/default/Display.template.php:
Search for:
// Show how many posts they have made.
echo '
', $txt[26], ': ', $message['member']['posts'], '<br />
<br />';
Replace:
// Show how many posts they have made and their member number
echo '
', $txt[26], ': ', $message['member']['posts'], '<br />
Member Number: ', $message['member']['id'], '<br />
<br />';
Thanks a lot guys :)
Quote from: Lamper on May 14, 2004, 03:32:39 PM
Just PM me. :)
Why you allways ask people PM you? There might are other users who like to know these thing also. Its kind hard search help from old posts if you allawys do it by PM. Just a thought.
Quote from: Lamper on May 14, 2004, 03:32:39 PM
This is also here
Where? I cant see this feature in here.
I think he means that the member ID information is already in the code...
I think maybe this should be included as an option in the admin panel, where you can activate or decativate viewage of member number in profile and on posts.
Quote from: Skoen on May 15, 2004, 08:12:08 PM
I think maybe this should be included as an option in the admin panel, where you can activate or decativate viewage of member number in profile and on posts.
agree
e.g. it's useful, to see which member have registered first in a forum
That can be a mod, just use Oldiesmann code and add something in admin options that will deactivate this or not...
if you want it,
pm me... j/k :) (owdy...:))
Personally, I don't see this as a terribly useful feature. In many cases, the member number makes no difference... and is only used in power struggles.
Another point is support. My "member number" is 2. There is no 1. If this were added by default, a very large number of people would come about wanting to:
- change this number for themselves or others.
- wonder how this number is generated.
- report bugs about "skipped" member numbers. (these are intentional!)
- ask if it is possible to make themselves "0" - it is not.
This is because of the way the ID_MEMBER is stored in the database and how it is handled by MySQL. Using it as a "member number" is misusing the field, and will only cause all the same problems you get from bad UI - which is why I am against it as a built in feature.
-[Unknown]
Actually, you could always make someone have a user number of 0... Just edit the code and basically check to see if the post was by that person, and if it was, just hard-code it in there and they'd never know the difference ;)
I do understand where [Unknown] is coming from. auto_increment doesn't re-use old numbers - it just automatically generates an ID_MEMBER number that is one higher than the previous one, even if that previous member doesn't exist anymore. Yes, you could always periodically update things but it would be a pain in the rear to do...
Hmmmm, Every user is his own number "0". :)
Hey guys,
I've tried coding this before and I have a serious problem with my forum.
Sometime long ago, before I think my YaBBSE, I was using just good ol' YaBB Gold or something and I had ran some mod that reorganized my member list, and it sorted all of my members number alphabetically.
For instance, Im BigMike and I think I am the 2nd person (as I had created a couple admin accounts back in the begining), so I should be Member #2 but instead I am like member #120 or something, and that's because back in the day I was alphabetically the 120th entry, and that then became my member number.
Now, since then, many more people with names alphabetically before "BigMike" have registered yet I am still num 120 - obviously - because it only affected those members who were already registered on that day that I had reorganized my member list. So now of course all members since then have their member number correct. I remember its somewhere around member #1400-something is where the problem ends and the correct member count begins. In other words I had 1400-something members at the time that my member list was re-organized so only those 1400-something members' numbers were changed, hence new members actually do have their correct number.
So, after I learned how to code this, I realized that the only real way to organize my member NUMBER is by registration date, since that has not changed!
But I am not that good at coding, so I just left it alone. But if someone could make is so that the members are sorted by actual registration DATE which is really their real member number then it would work on any board regardless of any conflicts like what Ive got...
.......man I cant remember what it was that screwed my board up.. This was seriously over 2 years ago. I think it was something that added more stats/options to the member page on Yabb gold or something, and it resorted all of the members alphabetically and it screwed up everyone's member number at "$context['member']['id']"
I hope this is clear what Im trying to say. Basically at the time that my forum got messed up, member #1 became the first alphabetical member, and member #1400-something became the last alphabetical member number..
So I think to code this it wouldnt be to complicated.. First make a script that would gather ALL of the registrants date of registration, sort them in order, and then change their member number to match their actual registration date - their true member number. Then I could just use what Oldiesmann wrote in reply #4 and everything would be good.
I guess you could call it a Member Number Restore Function. Something that goes through and resets all member numbers in according to their actual date/time of registration.
Anyone please? Thanks, you dont know how much this means to me. All of my competing companies forums has member numbers and every now and then my members ask me why we dont have it and it makes me pretty sad........
Regards,
BigMike
Ok I forgot to mention that I understand what Unknown is talking about, so could someone just create a new variable, then write a program that compares each users' registration date, and then sort them into this new variable by number then we would have a complete accurate list of each members number.
It could just be a simple feature in the maintenance area like "Rebuild Member's Number List" and it would just take a complete list of all members registration date and resort them starting at #1 and then store that number as their actual member number.
Wa-la.
But the whole point of IDs is to:
- be unique.
- never repeat.
- always stay the same.
Your Google standing would drop if you did this, and many profiles would fall off the index. You're looking at something that is NOT a member number, and calling it one.
-[Unknown]
................ok, that's fine, I understand that.
So my suggestion is to make a new list that is sorted by Registration Date since that is really the member number.
heh
BigMike
Is there a way to change the member number for people?
It'd just be nice if my admin people were the first "numbered" members on my list.
Also, is there a way to make the default view on the members page to show them in order of registration?
Is your ID really that important? It's only displayed in url's.
Regards
Number 8 on his own board.
Quote from: cheesenub on November 22, 2004, 06:09:10 PM
Is there a way to change the member number for people?
Not without causing a large number of unpreventable problems.
QuoteAlso, is there a way to make the default view on the members page to show them in order of registration?
This is already the default order, by virtue of the inherent and very often used properties of auto incrementing fields.
-[Unknown]
Quote from: [Unknown] on November 22, 2004, 07:55:26 PM
Quote from: cheesenub on November 22, 2004, 06:09:10 PM
Is there a way to change the member number for people?
Not without causing a large number of unpreventable problems.
QuoteAlso, is there a way to make the default view on the members page to show them in order of registration?
This is already the default order, by virtue of the inherent and very often used properties of auto incrementing fields.
-[Unknown]
Hmm, my view defaults by username, not by registration date.
Quote from: cheesenub on November 22, 2004, 08:02:15 PM
Hmm, my view defaults by username, not by registration date.
Darn, I guess that's right. I was thinking of something else, but I swear there was a member list that did...
Well, you can change that in Memberlist.php... find:
$_REQUEST['sort'] = 'realName';
Replace:
$_REQUEST['sort'] = 'ID_MEMBER';
-[Unknown]
Hey listen,
I dont know why this is being overlooked. You guys dont understand why people think their member number is important, BUT WE DO. Both of the major competing boards in our business have member numbers listed below each member in their posts. I think this is GREAT and I wish my SMF could do it. :'( It's very simple to see who the newbies are and to compare their post counts with their member number, very easy to monitor his/her activity. My forum is rather small, we only have around 2,500 members, but when it gets bigger, like 10,000 members, its gonna be so sweet to be like member #134. "Wow! You've been here since the beginning!!"
This really is a nice feature and it helps people give respect. Easy to see the elders of the board.
Now, with all of that said, I understand where you guys are coming from about the member id field and how it is not designed nor intended to be a chronological member number.
So my request is for someone who is willing to make a script that can populate a list of dates registered and sort them in order of date. And there should be an option in the Maintenance section of the admin to re-populate this list in case their is some order and it would go through the members again and recheck that they are in the correct order.
I am not suggesting to use the Member Id field as the chronological member order number, but instead create an entirely new array/variable/whatever, like $message['member']['registration_order'], that is the actual member id #.
Is this so hard to make ? I'm sorry that I am not a programmer, but you guys have built one hell of a forum system so I'm sure you are more than capable of doing this, it just seems like you guys think there is no support for it and no one wants it..........whatever.
Please let me know what you think about this. [Unknown]?
So, from what I understand, there is no 'member number'. This doesn't exist.
But there is something in the database which is the Member ID, an unique identifier automatically attributed when a user registers itself. And those IDs are not meant to be modified, in any way.
I believe it is not that hard to understand.
Personaly, I don't see too the real trip to be "Member #1", "Member #2", "Member #137" in a forum with 10000 members. You say it helps to give people respect ; I say you're wrong. Respect is based on what a user says in his posts, not on his seniority. It is based on how a person acts, not on his smallest number.
You say showing the "member number" would help to distinguish who's a newbie and who has been here since the begining: if it is really important to you to see which one is the oldest member, why don't you just show the registration date ?!
Just a thought...
well i have member nmbers for my members shown on display.template and the profile.template and i basically put it there not to distinguish n00bs from oldys, but because it was possible and it looks cool 8)
Thanks for your opinion, but I really wish I could see how members were added and in what order directly from the threads.
I agree that people show their character (on BBS) by what they say. I wasnt referring to the comparison of, for instance, member #3,456 with #3,457, but rather I want to see member #20 out of 20,000 still posting on my forum daily. It shows that he's been here for a long time and he must really love the place. Guests can see that and think, why these people have been here for over 2 years, this must be a great place.........................somewhere along these lines.
I could show the registration date, like "Registered: Nov, 2004" and that would work also, but you just cant grasp where in the history time-line of the forum that occurred in comparison to other members, which is the whole idea of a member id #.
Also it's more interesting to refer a friend to my forum by saying "Hey you should check out this forum! I'm the 456th member!"
That sounds better than "Hey you should check out this forum! I registered on this date"
My members agree that by having a member number, they feel like they are more a part of the forum. "I'm number 1,345."
Actually in my business, every singe dual case adapter and gear set that we've sold in the 9 years of business has gotten its own unique id number. For instance, the MC08 adapter on my pickup is #122T, the MC08R10 is #001T, and my 4.70:1 gear set is #1444T. So our members/customers are already involved with identifying numbers from our company so they like the idea of having a member number on our company forum.
BigMike
It's really easy to show the member's ID next to messages. It's available in Display.template.php's template_main(), under $message['member']['id'].
You could do something like
<edit file>
$themedir/Display.template.php
</edit file>
<search for>
// Show how many posts they have made.
echo '
', $txt[26], ': ', $message['member']['posts'], '<br />
<br />';
</search for>
<add before>
// Show the member's ID.
echo '
', $txt['who_member'], ' #', $message['member']['id'], '<br />';
</add before>
(http://board.marlincrawler.com/index.php?action=dlattach;topic=4798.0;id=5595)
I'm afraid I don't understand what that means... :P
Edit: I just read the whole topic again and understood. Sorry, it's such an old topic that I forgot about those replies.
Quote from: BigMike on November 22, 2004, 09:09:16 PM
This really is a nice feature and it helps people give respect. Easy to see the elders of the board.
You think? Personally I judge people on the quality of their posts, not how long they have been a member.
Quote from: Ben_S on November 23, 2004, 05:08:14 AM
Quote from: BigMike on November 22, 2004, 09:09:16 PM
This really is a nice feature and it helps people give respect. Easy to see the elders of the board.
You think? Personally I judge people on the quality of their posts, not how long they have been a member.
Agreed.
Quote
So my request is for someone who is willing to make a script that can populate a list of dates registered and sort them in order of date. And there should be an option in the Maintenance section of the admin to re-populate this list in case their is some order and it would go through the members again and recheck that they are in the correct order.
Let's see if this helps you... (remember to backup first, this is provided
"as is" without warranty of any kind)
Add the new column for member number to your members table
ALTER TABLE `smf_members` ADD `MemberNumber` MEDIUMINT( 8 ) UNSIGNED NOT NULL ;
Put the attached script in your forum's dir and load it in your web browser to update the new column's values. Remove the file after you're done.
Do the following modification
<edit file>
$sourcedir/Load.php
</edit file>
<search for>
);
$select_columns = "
IFNULL(lo.logTime, 0) AS isOnline, IFNULL(a.ID_ATTACH, 0) AS ID_ATTACH, a.filename, mem.signature,
</search for>
<add after>
mem.memberNumber,
</add after>
<search for>
'id' => &$profile['ID_MEMBER'],
</search for>
<add after>
'number' => &$profile['memberNumber'],
</add after>
Now do what I wrote in my other reply, but instead of
'id', use
'number'.
I'm not giving any interface to handle this, nor am making it auto-update. If you need to fix the member number for the new ones, just repeat the part with the script.
If somebody wants to improve this, be my guest.
If I get *really really* bored in the next few weeks I *may* attempt to write a little sorting script. However, it really is a hell of a script to write as ID_MEMBER is god damn everywhere, so means altering a tonne of tables and then altering them back - can I be bothered is the question (And will I find time!)
Especially to Anguz, and for Grudge, thankyou guys for checking this out for me (us). I'm sure I'll have some free time during turkey weekend to take a stab at Anguz's code and I'll let you know how it goes ;D
Grudge, if it takes ya a long time, then you dont need to do it on my behalf. Maybe if there is more interest then you would feel better coding it? Yes I really want it done, but damnit I wish I could code half of what you guys have forgotten! Then I could help do some work! All I learned was html, c++, and javascript.. MySQL is another world to me. I've only learned what I know from reading your guys' forum software ;D
Anguz- I was just sifting through your coding. Correct me if Im wrong, but this is just to copy the member id over to a new variable, right?
Hopefully my backup feature will start working. I used to make weekly backups, but now the page takes like 10 mins and then it says something like "the referring url is not responding or is unavailable." I think its something with my host because it does the same thing when I try to make a manual backup through the phpMyAdmin as well..
Quote from: Ben_S on November 23, 2004, 05:08:14 AM
You think? Personally I judge people on the quality of their posts, not how long they have been a member.
Please read reply #26 on Page 2. ;)
Oh yeah, Grudge I almost forgot..
If you are going to code this, then if its possible, then try to sort based on $context['member']['registered']. Don't base it off of ['member']['id'] since that's the whole reason its not working (my ['id'] numbers are no longer in order and Unknown says we shouldnt alter that variable).
But the $context['member']['registered'] value of course is in order on everyone's board unless they went into their sql admin and manually changed it. And the registered date is the perfect way to organize the member # by :)
The reason [Unknown] told you not to change the member ID number is because you would have to update a bunch of other tables as well (PMs, messages, boards, topics, polls) and unless you do it just right, you could end up messing things up. I did this on my site when I switched from a custom site with YaBB SE to LSP Enigma (also uses YaBB SE), and it was a pain even with YaBB SE. I didn't update PMs or anything, and there really weren't many polls, but still it was a pain in the rear to do it.
Quote from: BigMikeAnguz- I was just sifting through your coding. Correct me if Im wrong, but this is just to copy the member id over to a new variable, right?
No. I get all the members from the db sorted by date registered and then number them in that order and save it in the new table column. I don't modify the IDs at all, which makes it simpler.
Quote from: Anguz on November 23, 2004, 06:23:43 AM
Add the new column for member number to your members table
ALTER TABLE `smf_members` ADD `MemberNumber` MEDIUMINT( 8 ) UNSIGNED NOT NULL ;
which file is this in again anguz?
I think its the direct phpMyAdmin script that needs to be ran from within your MySQL.
Quote from: BigMike on November 22, 2004, 09:09:16 PM
Hey listen,
I dont know why this is being overlooked. You guys dont understand why people think their member number is important, BUT WE DO...
At some point in time an admin has to learn how to tell his/her members
no.
Quote from: Elijah Bliss on November 24, 2004, 03:06:36 AM
At some point in time an admin has to learn how to tell his/her members no.
::)
Quote from: BigMike on November 24, 2004, 02:35:45 AM
I think its the direct phpMyAdmin script that needs to be ran from within your MySQL.
Yup.
Quote from: [Unknown] on November 20, 2004, 08:10:18 PM
But the whole point of IDs is to:
- be unique.
- never repeat.
- always stay the same.
Your Google standing would drop if you did this, and many profiles would fall off the index. You're looking at something that is NOT a member number, and calling it one.
-[Unknown]
I am revisiting this idea, and I wanted to ask Unknown how this would affect the Google standing?
Remember, I HAVE NEVER requested to change the member ID in ANY WAY, but rather to create a new variable with the correctly sorted member number.
I am going to take another jab at this in the next couple of weeks. I really wish this feature was a default option.
Regards,
BigMike
Any updates on this? I just spent a good 10 minuets looking through the mod site and could not find a new mod for it.
Every time I visit our competitor's vB forum and I see "Member #1234" below some user's avatar, I HATE IT. I am so jealous and I wish SMF could do this!!
In vain,
BigMike
It can. It's a template thing. Hover a member name in the topic and look at the end of the URL. You just have to display that number the way you want to in the template you use.
Well, that will not work for me because the SMF member ID number is not intended to be in any sort of order, and sometime ago when I was using YaBB Gold or YaBB SE, all of my member ID numbers were changed alphabetically by each member's user name.
But I think I figured something out from another script I have been playing with, but I need help with one thing.
If I use this code:
$regdays = (int) ((time() - $message['dateRegistered']) / (3600 * 24));
Then it will generate a numerical number for the number of days a user has been a member on the forum.
So!! all I have to do now, is take that number, $regdays, and subtract it from the number of days since the forum was created!
For instance, today, I have been a member of my forum for 2002 days. And since I was the first member created, of course the number of days since my forum was created is 2002. Therefore if I do this:
$memnumber = ((forum lifetime) - (my lifetime)) + 1;
Then I could write:
echo ' Member #: ' . $memnumber;
So all I need help with is being able to get access somehow to the original date of the forum in the Display.template.php file, and I could do it!!
Because I don't know how to come up with the value of the forum's life span, I tried setting $memnumber equal to my own # of days, and then I could subtract all other members from this (since I predate all other members), but I failed to get it done.
Could someone help! How can I get the value of the forum life time into the Display.template.php!!?
Thanks!
BigMike
By the way,
This is precisely what I requested in Nov of 2004........... 3 years ago!
Quote from: BigMike on November 17, 2004, 05:55:05 PM
But if someone could make is so that the members are sorted by actual registration DATE which is really their real member number then it would work on any board regardless of any conflicts like what Ive got...
Quote from: BigMike on November 22, 2004, 09:09:16 PM
I understand where you guys are coming from about the member id field and how it is not designed nor intended to be a chronological member number.
So my request is for someone who is willing to make a script that can populate a list of dates registered and sort them in order of date. And there should be an option in the Maintenance section of the admin to re-populate this list in case their is some order and it would go through the members again and recheck that they are in the correct order.
I am not suggesting to use the Member Id field as the chronological member order number, but instead create an entirely new array/variable/whatever, like $message['member']['registration_order'], that is the actual member id #.
So in 3 years all I've been able to do is find useful code from a script someone else wrote. Obviously I am not able to do this on my own.
I've since learned that no sorting script is needed; the required information can be acquired explicitly!
BigMike
I see what you mean, but member numbers *are* in order, I don't understand why they don't work for you. If you use the days since method, you'll have trouble sorting members registered on the same day.
Thanks for the reply :)
Hmmmmmmmmmmm............... Does the days since method give only a whole number value? I was hoping it gave an exact second value
If it returns a second value, then someone who registered a hour before someone else, would have been a member for 3600 seconds longer, and hence could be sorted. But if its a whole day value, then yeah, I can see how it would not work..
Regarding my forum, I don't remember what I had done, but it was back when I was still using YaBB Gold (before I converted my forum to YaBB SE and before SMF, its been through a lot ;))............. I believe it was something related to an option to sort the member list? So my member ID numbers have been way out of order for a good 4-years..
If you do the time-since in seconds, I doubt you'd have the problem I mentioned for days. Still, not having to calculate that would be faster and easier.
SMF does member IDs different than its predecessors, if I remember correctly. If I understood what you want to accomplish, it shoud be fine with the member ID. Members are assigned their IDs in the order they register.
BTW, using the time-since method you'd only be able to sort the displayed members for the current page, cause in order to know their position in the whole members list, you'd have to query the database and find out. It's faster and simpler to use the ID for the member and trust its ordered by registration time (more precise than date). Some ID numbers will be missing for some reasons, one of them deleted accounts, but it's not a problem and hardly noticeable.
when will this mod available for SMF 1.1.10 ?
If you mean http://custom.simplemachines.org/mods/index.php?mod=1652 you will need to install Version Emulate Dropdown (http://custom.simplemachines.org/mods/index.php?mod=2113) and use the dropdown that gives you to select version 1.1.8, then you should be able to install the mod.
hehe my first post ^__^ sir we really need this but it only works on the oldest SMF version how about us 2.0 version of smf? hope someone will update this thank you!
Apart from the fact that the same code would work with almost no changes, I'm still hazy as to what actual benefit this gives.
Boss could you teach me how can I install that on 2.0 SMF? I tried 1.x but I don't see the maker's finding codes.
It is slight different admittedly but not hugely so.
So what theme are you using? All it will do is simply point out who's been there longer, nothing more and that's information most users don't care about.
Profile.template.php: if ($context['user']['is_owner'] || $context['user']['is_admin'])
echo '
<dt>', $txt['username'], ': </dt>
<dd>', $context['member']['username'], '</dd>';
if ($context['user']['is_owner'] || $context['user']['is_admin'])
echo '
<dt>', $txt['username'], ': </dt>
<dd>', $context['member']['username'], '</dd>';
echo '
<dt>', $txt['member_number'], '</dt>
<dd>', $context['member']['id'], '</dd>';
Then, in index.yourlanguage.php, add this above the end (?>) of the file:$txt['member_number'] = 'Member Number: ';
You can translate that text into your own language if you wish.
Clear your cache (Admin » Forum Maintenance » Routine - Empty File Cache) if the text string doesn't appear at first.
EDIT: This *may* not work on a theme with its own Profile.template.php. So, if you have one, please say so.
Hi! How it works perfectly!
but is this possible to put it between
Quote# Posts: 7
# Karma: +1/-1
where you can see at the left side after they post.
Thank you!
In Display.template.php: // Show how many posts they have made.
if (!isset($context['disabled_fields']['posts']))
echo '
<li class="postcount">', $txt['member_postcount'], ': ', $message['member']['posts'], '</li>';
// Show how many posts they have made.
if (!isset($context['disabled_fields']['posts']))
echo '
<li class="postcount">', $txt['member_postcount'], ': ', $message['member']['posts'], '</li>';
echo '
<li class="postcount">', $txt['member_number'] . $message['member']['id'], '</li>';