vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Question about rights (https://vborg.vbsupport.ru/showthread.php?t=104807)

Eagle Creek 01-08-2006 06:04 PM

Question about rights
 
Hi people!

I have added more information to the postbit_legacy template:
PHP Code:

            <div class="smallfont">
                &
nbsp;<br />
                <if 
condition="$post['joindate']"><div>$vbphrase[join_date]: $post[joindate]</div></if>
                <if 
condition="$post['field2']"><div>$vbphrase[location_perm]: $post[field2]</div></if>
                <if 
condition="$post['age']"><div>$vbphrase[age]: $post[age]</div></if>
                <
div>$vbphrase[posts]: $post[posts]</div>
                <
br>
                <if 
condition="$post['field3']"><div><b>Besturingssysteem</b>: $post[field3]</div></if>
                <if 
condition="$post['field5']"><div>Gewenste moeilijkheidsgraad antwoorden (1-5):<br$post[field5]</div></if>
                <
br>
                <if 
condition="$show['reputation']"><div><if condition="$show['reppower']">$vbphrase[reppower]: $post[reppower]</if>$post[reputationdisplay]</div></if>
                <
div>$post[icqicon$post[aimicon$post[msnicon$post[yahooicon$post[skypeicon]</div>
            </
div

As you can see I use the custom profile fields 'besturingsystseem' and 'gewenste .. etc..'.

But I want to add another field. That's not the problem as you understand. The problem is I only want to show that field to the authorized persons. So I made the field, I set it to "private", "not searchable", and "no show on members list".
The field isnt Editable by User.
I gave my moderators permission to view the whole user profile.
What I want to do is: make a private profile field, only editable by mods/smods.

Now my real question: I want to show this field directly in the thread. So I think I will use:
PHP Code:

                <if condition="$post['field5']"><div><b>Private field</b>: $post[field3]</div></if> 

.

But will other people see this text then? And the content of it?

Because it's a private field I guess they (=other members) don't see the content but still see the text I put in the postbit. How can I prevent this?

peterska2 01-08-2006 08:41 PM

If it is for Super Mods and Admins to see that you can you the condition
Code:

<if condition="$show[modcplink]">blah</if>
Otherwise you will have to write a condition that includes regular mods too, but I'm not awake enough to think of that one off the top of my head. I need lots more caffine first.

Eagle Creek 01-08-2006 09:17 PM

Quote:

Originally Posted by peterska2
If it is for Super Mods and Admins to see that you can you the condition
Code:

<if condition="$show[modcplink]">blah</if>
Otherwise you will have to write a condition that includes regular mods too, but I'm not awake enough to think of that one off the top of my head. I need lots more caffine first.

No it's not only S-mod/admin.
I use a special usergroup (Qualified Helpers). I want them to view the item.
They are member of the usergroup QH but they are also moderator of a forum (so not in the mod UG).

Maybe that will make it more easier to make something?

You don't have ro rush, just take as much caffine as you like :D. Thank you in advance!

Edit: You say 'if condition = show MODCP link". But all the moderators can see them, can't they?
*testing*
hmm.. they can't... but I asked at vB.com a while ago and they gave me a change to show the CP to my mods..
It's like this:
Quote:

Take
PHP Code:

<if condition="$show['modcplink']"><a href="$modcpdir/index.php?$session[sessionurl]">$vbphrase[mod]</a> -</if> 

And change it to:
PHP Code:

<if condition="can_moderate()"><a href="$modcpdir/index.php?$session[sessionurl]">$vbphrase[mod]</a> -</if> 


http://www.vbulletin.com/forum/showp...78&postcount=2

When I re-apply that idea, will your code work then?

peterska2 01-08-2006 09:20 PM

Code:

<if condition="can_moderate()">code</if>
would work then as long as all QH are mods.

Eagle Creek 01-08-2006 09:28 PM

Here I'm back..

When a person is member of the group QH, and has moderation rights he can see the MOD-link now in the navbar.
All the QH's do have moderationrights.

So would you thing work now?

peterska2 01-08-2006 09:30 PM

yeah providing both conditions are true.

Eagle Creek 01-08-2006 09:32 PM

Quote:

Originally Posted by peterska2
yeah providing both conditions are true.

I'm going to change some things at my forums! THANKYOU FOR THE HELP :D.

peterska2 01-08-2006 10:15 PM

no prob, any time :)


All times are GMT. The time now is 10:27 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01065 seconds
  • Memory Usage 1,757KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (4)bbcode_php_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete