• Welcome to Simple Machines Community Forum. Please login or sign up.
December 06, 2021, 11:03:10 AM

News:

SMF 2.1 RC4 has been released! Try it out and help us test! :) Read more.


Where is a member's profession displayed?

Started by brucegust, November 25, 2019, 09:15:54 PM

Previous topic - Next topic

brucegust

I just updated my client to version 15. She was using 7 so I'm guessing there may very well be several changes in terms of navigation and what's displayed, but I don't know...

Here's the thing:

It used to be that when you logged on to the Admin page, you would in the upper left hand corner an alert that told you how many members were awaiting approval. You would click on that link and be given a list of candidates and from there you could see each of their respective professions.

At this point, she doesn't have any members awaiting approval, but she is seeing activity in the Messages section that's been created by users that she recognizes as bogus. What's made it easy to confirm her suspicions was the profession of these renegades. But when you click on "View the Member List," there's no reference to their profession and when I look at the member table, I don't see a column heading that suggests this info is even available in the system.

Am I missing something?

Where would a user's profession be displayed?

Sir Osis of Liver

Sounds like advanced profile fields.  Upgrade shouldn't have broken that if you patched from .7 to .15 in package manager.
Look in Admin -> Core Features, is Advanced Profile Fields enabled?  Do you see the field in Admin -> Features and Options -> Profile Fields?
"The best laid schemes o' mice an' men / Gang aft a-gley." - Robert Burns

brucegust

Evening, Sir!

Since posting this, I found something: In the database, there's a table called "smf_custom_fields." In that table, I see "Occupational Specialty," so it is in the system!

But...

I don't know how to ensure that field is accessible and it sounds from your post that there's a setting I need to activate in order for it to be displayed.

When I go to Admin, I don't see "Core Features." The "Profile Fields" suggestion you made sounds completely on point, but I don't how to get there.

When I go to "Features and Options," I don't see Profile Fields.

What do you think?

brucegust

OK! I did find "Profile Settings" and I was able to activate it! But it's still not displaying on the user's individual profile or on the member list. Is there a way in which you can dictate where the field shows up?

Here's a screenshot of what I'm looking at...


brucegust

This is where I want the "occupation" specialty profile setting to show up.

efk

Slow down, click on Modify button and you should be able to set it be like that from given options, read what you have inside Modify. About Standard Profile Fields, I think they can't be modified the same way you can manipulate with Custom Profile Fields. So go experiment for some time before asking more questions :)
Not sure atm, but you might need mod to display on member list.

brucegust

This is what I get when I click on "Modify..."

There's nothing on this screen that I can find that would facilitate the field showing up on a list of members anywhere in the app.

What am I missing?

brucegust

Admin -> Configuration -> Features and Options -> Profile Fields -> Modify

That's where I'm at. Let me know if I need to go somewhere else.

Arantor

Showing them on the memberlist is not a feature in 2.0, but it is in 2.1.
No good deed goes unpunished
All helpful urges should be circumvented

Sir Osis of Liver

November 26, 2019, 04:42:17 PM #9 Last Edit: November 26, 2019, 04:52:33 PM by Sir Osis of Liver
It can be done (think I did it once), requires some custom coding.
"The best laid schemes o' mice an' men / Gang aft a-gley." - Robert Burns

efk


brucegust

eftk...

Not sure whether or not the number of errors contained in the test installation of this mod represents a dealbreaker or not. I have made a backup of everything, so I've got a net, but if this was you, would you proceed or would you be looking for another option?

Here's a screenshot:


Sir Osis of Liver

If you click on the edit widget left side, it will show you the target code and the edit, you can do it manually.  If you proceed with the install as is, bad things will happen.
"The best laid schemes o' mice an' men / Gang aft a-gley." - Robert Burns

efk

brucegust I am wrong guy to ask that, but when I see problems I always avoid. Also there is at bottom in Package Manager "Advanced" and there you can emulate version before installing, but I usually let friends to play with that, and last time when I've touched that was about year ago. Also search for topic for that mod, maybe there are some instructions that you need to know. I always read a lot about mod before installing, and from that I learned almost all what I know, also have lists of useful mods on side.
And of course, listen what people with nice amount of posts are saying to you.

aegersz

Yes, I tried to install that and after making the modifications manually on 2.0.15, i got this:

Table 'smf209.custom_fields' doesn't exist
File: /var/www/html/Packages/temp/install.php
Line: 16


the only difference is the "." after smf209 - i use a "_" so it won't install anyway !
The configuration of my Linux VPS (SMF 2.0 with 160+ mods & some assorted manual tweaks) can be found here and notes on my mods can be found here (warning: those links will take you to a drug related forum). My (House) music DJ dedication page is here

aegersz

December 02, 2019, 12:33:45 AM #15 Last Edit: December 02, 2019, 12:57:37 AM by aegersz
Just for you - I got this working on 2.0.15 (still have an issue with the config formatting though) by:

1. I had to unzip the mod into it's own directory in .Packages

2. I had to make the minor manual changes to the existing code

3. modify install.php and removed any database code to now look like:

<?php

if (file_exists(dirname(__FILE__) . '/SSI.php') && !defined('SMF'))
{
        
$ssi true;
        require_once(
dirname(__FILE__) . '/SSI.php');
}
elseif (!
defined('SMF'))
        exit(
'<b>Error:</b> Cannot install - please verify you put this in the same place as SMF\'s index.php.');

?>



4. add the column into the table (your db and table name may vary):

USE smf209;
ALTER TABLE smf209_custom_fields
ADD   show_mlist tinyint(3)
;


5. check the box to display on memberlist in Admin -> Features and Options -> Profile Fields > Profession (that i added)

it works now on 2.0.15 !
The configuration of my Linux VPS (SMF 2.0 with 160+ mods & some assorted manual tweaks) can be found here and notes on my mods can be found here (warning: those links will take you to a drug related forum). My (House) music DJ dedication page is here

aegersz

forget all that, the field displays in the Topic anyway and the memberlist field still eludes me  :P >:(
The configuration of my Linux VPS (SMF 2.0 with 160+ mods & some assorted manual tweaks) can be found here and notes on my mods can be found here (warning: those links will take you to a drug related forum). My (House) music DJ dedication page is here

brucegust

Guys, this is still a "thing..."

I went out to https://custom.simplemachines.org/mods/index.php?action=parse and went through every change in the code by hand, uploaded it and got an error that was generated from the "MemberSettings.php" page that said, "show_mlist" isn't a column in the 'custom_fields' table."

And they're right.

Any other ideas?

This was a fixture in my client's previous version and I really do want to figure it out.

Again, I just want to have one more column on the page that displays the members. That column would be their occupation.

Arantor

Well, the plugin would have a script that would have to be run to add the show_mlist column... it'll be part of the zip file and the parse page should indicate you have to run this.

And we understand your need and what you're trying to do, just this is not something the core supports at this time, so you'll need to reimplement it using that mod.
No good deed goes unpunished
All helpful urges should be circumvented

brucegust

The problem with the zip file is that when I attempted to upload it and run it, it generated all kinds of errors, however...

Popping the hood on the install.php page, I see your point.

Can I just run the install.php page from the root directory on its own? Seems like the only thing that its affecting is the database. All of the other code modifications have been done.

Advertisement: