• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

About Tab 1.0

No permission to download
Shows the user's information in a separate tab

Robust

Well-known member
#1
Robust submitted a new resource:

About Tab - Shows the user's information in a separate tab

This add-on allows you to have the user's about information in its own tab. Currently it is in the Information tab. This add-on removes it from the information tab and adds it into its own tab (called About).

Installation
1. Unzip AboutTab.zip
2. Upload addon-aboutTab.xml to your forum
Read more about this resource...
 

Robust

Well-known member
#5
Would like to create user fields questions/answers for users under your tab, is it feasible?
Oh, you mean you want to add new user fields into the tab? It's easily possible, but it requires messing around with templates. Since I use a template modification to make the change and add the tab in, you'd have to modify my template modification. The hardest part of this process is getting your board into debug mode.

Go to library/config.php and add the line:
$config['debug'] = 1;

Refresh your admin control panel. Go to Appearance -> Template Modifications -> Look for a row that says member_view, it should be below a little row saying About Tab. Go into the Replace box and add your fields in.

Code:
<dl><dt>Text:</dt> <dd>{xen:string censor, $user.occupation}</dd></dl>
Change $user.occupation to $user.(fieldname). Check the field name at Admin Control Panel -> Users -> Custom User Fields -> Click on the one you want -> Copy the field id.

Screen Shot 2015-05-04 at 10.12.42.png

Once done, put your board out of debug mode:

Remove the line: $config['debug'] = 1;
Set it to zero: $config['debug'] = 0;
Or comment it out (what I do): //$config['debug'] = 1;

If there are any problems or queries, please let me know.
 

Pinn

Active member
#6
I have done it without problems. Only I have a problem that the questions which I've now created under the tab about to other user information fields are displayed now and that should not be. Do you have an idea?
 

Attachments

Robust

Well-known member
#7
I have done it without problems. Only I have a problem that the questions which I've now created under the tab about to other user information fields are displayed now and that should not be. Do you have an idea?
Got a screenshot?
 

Robust

Well-known member
#9
@Pinn Oh, I see. There's another template modification I used to remove them from the information tab. Let me install this real quick on my new development board and check it for you.
 

Robust

Well-known member
#10
@Pinn Hm, I completely overlooked this part. Fields are added through a loop. There are a couple of ways to remove them. The proper and the recommended way would probably require PHP code. If you wanted all of the personal user fields moved into the about tab, it's a lot easier. To move specific ones would require some PHP code accustomed to your installation (or a selector in the Options part of the panel, which shows all custom fields and allows you to select which ones should go under About, which could come in a future update).
 

Pinn

Active member
#11
MH okey. My concern is that I would have gladly answer users questions. Therefore, it must be displayed in a private tab. An own addon should probably be created.
 

Robust

Well-known member
#12
MH okey. My concern is that I would have gladly answer users questions. Therefore, it must be displayed in a private tab. An own addon should probably be created.
It wouldn't be hard to make something like that up. I can make a selection list as an admin option and let you choose which fields you want to be added into the About tab and removed from the other tabs. I'll see if I can do it over the weekend.
 

Robust

Well-known member
#15
I got the backend part of it done but I don't have a clue on how to make the frontend part to send the data/array of tab name and field name, with a field name selector. I'll look at some XF examples later I guess.
 

Pinn

Active member
#16
I got the backend part of it done but I don't have a clue on how to make the frontend part to send the data/array of tab name and field name, with a field name selector. I'll look at some XF examples later I guess.
Okey, unfortunately can not help you, know even less. Ask in the Forum here.
 

Pinn

Active member
#17
Is there anything new?

A new resource would be awesome with questions and answers, which are then evaluated as who responded and compares what eg responded X what one has just answered.