vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=192)
-   -   Profile Enhancements - Social Networking Fieldset in User Profile & Postbit (https://vborg.vbsupport.ru/showthread.php?t=174863)

ChU v2 04-08-2008 01:07 AM

Quote:

Originally Posted by funkmeister (Post 1485585)
How do you prevent the added field information from showing up in the "Additional Information" section of the Member's profile?

Thanks, good work :up:


Set the profile fields to private. You as an Admin still can see the private profile fields as far as I know.

funkmeister 04-08-2008 05:26 PM

OK, thanks, got that working, but in my case, I had to set "Can View Private Custom Fields" to 'No' in the Usergroup permission section.

The problem I have left now is, that they're not showing up in the Postbit. Any clues where I should look to get that working? As an Admin, everything looks good, but as general user, they're not showing up there. One note of interest, is if I set "Can View Private Custom Fields" to 'Yes', the postbit works for Admin & general users, but then it won't display in the Member Profile for general users! So I'm going around in circles!

Any ideas, appreciated!!

Many thanks.

ChU v2 04-08-2008 08:56 PM

Quote:

Originally Posted by funkmeister (Post 1486098)
OK, thanks, got that working, but in my case, I had to set "Can View Private Custom Fields" to 'No' in the Usergroup permission section.

The problem I have left now is, that they're not showing up in the Postbit. Any clues where I should look to get that working? As an Admin, everything looks good, but as general user, they're not showing up there. One note of interest, is if I set "Can View Private Custom Fields" to 'Yes', the postbit works for Admin & general users, but then it won't display in the Member Profile for general users! So I'm going around in circles!

Any ideas, appreciated!!

Many thanks.

Well come other options that I would check : Usergroup options > general permissions

Can view member info: Yes

Also maybe the profile field has to be NOT set to private.

And maybe in vBoptions > User profile options

vB code in non forum specific areas: Yes

funkmeister 04-08-2008 09:47 PM

Thanks for the ideas, but the only option that helps is the one I was asking about initially.

If I make the new profile field NOT private, it does indeed work in the Postbit as well, but then I'm left with that field name and user info shown in the Member Profile, under "Additional Information". So it's displaying there on it's own and also to the right of that, in the new "Social Networking" section. Which is not really good to look at :(

Is this not what everyone else is experiencing? Am I alone with this? I don't understand what could be different for me? Or is this the way it's supposed to display?

Thanks.

Jenkins 04-10-2008 01:08 AM

does this work with 3.7?

ChU v2 04-11-2008 01:23 AM

Quote:

Originally Posted by Jenkins (Post 1487129)
does this work with 3.7?

The code would work fine, it's a matter of finding where to put the code within those templates because they are different from 3.6x

deLi_kurT 05-03-2008 09:48 PM

Thanks - installed

sdavis2702 05-04-2008 03:22 AM

Thanks my members have been asking for this :)

EDIT: Ugh... for some reason I can not get these icons to show in the postbit. Am I the only one?

sdavis2702 05-04-2008 07:11 AM

Got it.... I did all of the editing in my postbit legacy template... I should have been in postbit :( Good to go now :)

Is there any way to make it show next to the standard icons instead of in it's own seperate "Social Networking" section in the postbit? My postbit is starting to stretch the area out and makes the avatar look tiny and out of place.

EDIT: I figured it out. I'm pretty new to this so I had never seen the "Fieldset" code before that was surrounding this area and labeling it "Social Networking". Common sense told me that it was putting the box around the icons considering it said "Social Networking" on it. I deleted the codes and it cleaned it up a little bit for me. Good to go now thanks again lol.

sdavis2702 05-04-2008 08:25 AM

Okay this is the last time I will post I promise :) Okay, though I solved my problem posted above, I still was unsatisfied because I wanted the new icons to show next to the standard ones (yahoo, msn, etc.) I have found that a lot of members really only have Yahoo and AIM so I didn't feel it was necessary to have a second row for icons. So here is what I did...

I completely did away with the Social Networking section that we pasted into the postbit template originally. Here is what I deleted:

PHP Code:

<if condition="$post['fieldXX'] OR $post['fieldXX'] OR $post['fieldXX'] OR $post['fieldXX'] OR $post['fieldXX']">
<!--
Social Networking--> 
<
div class="smallfont" align="left">
<
fieldset><legend>Social Networking</legend>
<if 
condition="$post['fieldXX']">
<
a href="http://www.myspace.com/$post[fieldXX]"target="_blank"><img src="$stylevar[imgdir_misc]/myspace.gif"border="0"alt="View Member's Myspace Profile"></a>
</if>

<if 
condition="$post['fieldXX']">
<
a href="http://www.facebook.com/$post[fieldXX]"target="_blank"><img src="$stylevar[imgdir_misc]/facebook.gif"border="0"alt="View Member's FaceBook Profile"></a>
</if>

<if 
condition="$post['fieldXX']">
<
a href="http://youtube.com/user/$post[fieldXX]"target="_blank"><img src="$stylevar[imgdir_misc]/youtube.gif"border="0"alt="View Member's YouTube Profile"></a>
</if>

<if 
condition="$post['fieldXX']">
<
a href="http://myworld.ebay.com/$post[fieldXX]"target="_blank"><img src="$stylevar[imgdir_misc]/ebay.gif"border="0"alt="View Member's eBay Profile">
</if>

<if 
condition="$post['fieldXX']">
<
a href="http://live.xbox.com/member/$post[fieldXX]"target="_blank"><img src="$stylevar[imgdir_misc]/xbox.gif"border="0"alt="View Member's Xbox Profile"></a>
</if>
</
fieldset>
</
div>
<!--/
Social Networking-->
</if> 

The reason I did that is because like I said, I didn't want it in a seperate section. After doing that, I copied the icon links (the seperate sections of each site) that were in the text I deleted, and I pasted them into the text we used to FIND that section. Here is what I mean...

In postbit_legacy (just postbit for me) we FOUND:
PHP Code:

<div>$post[icqicon$post[aimicon$post[msnicon$post[yahooicon$post[skypeicon]</div

Well after staring at everything I realized that these are the spots for the standard icons in the event the user has entered info in one of these fields in their profile. Remember this is where I wanted my new icons to go as well. So... I pasted the site sections I was using (MySpace & FaceBook) right after "$post[skypeicon]" in the above text. Here is what it looked like after doing that...

PHP Code:

<div>$post[icqicon$post[aimicon$post[msnicon$post[yahooicon$post[skypeicon

<
a href="http://www.myspace.com/$post[field13]"target="_blank"><img src="$stylevar[imgdir_misc]/myspace.gif"border="0"alt="View Member's Myspace Profile"></a>

<
a href="http://www.facebook.com/$post[field14]"target="_blank"><img src="$stylevar[imgdir_misc]/facebook.gif"border="0"alt="View Member's FaceBook Profile"></a

After pasting the new icon links in there, they showed up on EVERYONE'S postbit. That's NOT what I was looking for. The reason this happened is because the links were no longer in condition tags. The icons will show up no matter if the member put info in that field or not. If they had info there, clicking the icon would still take you to their page. But if they didn't put info there, it would take you to that websites homepage.

Obviously I didn't want this either (starting to see how much trial & error I had? lol). So I played around with conditionals. I went back to the original text Nick (ChU v2) gave us and took the conditionals he used. No need to reinvent the wheel. I put the conditionals around my new icon links as a whole AND I put conditionals around each site seperately. Here is what it looked like after that...

PHP Code:

<div>$post[icqicon$post[aimicon$post[msnicon$post[yahooicon$post[skypeicon]
<if 
condition="$post['field13'] OR $post['field14']">
<if 
condition="$post['field13']">
<
a href="http://www.myspace.com/$post[field13]"target="_blank"><img src="$stylevar[imgdir_misc]/myspace.gif"border="0"alt="View Member's Myspace Profile"></a></if>
<if 
condition="$post['field14']">
<
a href="http://www.facebook.com/$post[field14]"target="_blank"><img src="$stylevar[imgdir_misc]/facebook.gif"border="0"alt="View Member's FaceBook Profile"></a></if></div></if>
                </
div

Keep in mind, my fields are in that text. So if you copy that, change the "field13" and "field14" to whatever your fields are.

NOTE: I only used MySpace and Facebook. Using all of the ones he gave us will probably cause a problem if the user has info in every field on the profile. I would think that too many icons showing will distort the layout somehow. For my site, even if they have all 5 standard fields AND MySpace & FaceBook, we'll still be good because everything will fit. If you're using everything I don't know if it will work. I would think the icons wouldn't fit. Then again, it may be set up to wrap around and start another row. I have not clue!

Alright well that's it. I now have what I want and it only took me forever :)

NOTE: Please don't bash me. I have only had my forum for one month and before that, I had never seen this stuff before in my life. If there was a much easier way to do it, I didn't know about it lol. I really just used common sense and patience to figure this out. This is probably basic stuff to most of you. Anyway that's what I did and I have what I want. Thanks to the creator of the hack... I learned a TON of stuff messing around with this one. It's now valued as more than just a hack to me... I appreciate it!

Here's how it looks for me now considering I only have AIM, Yahoo, and MySpace...

BEFORE: Attachment 79867 AFTER: Attachment 79864

And for those of you looking at my backwards post count... yes I did go back and change it to the way I didn't like it just so I could attach the "BEFORE" picture lol :)


All times are GMT. The time now is 01:21 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.01183 seconds
  • Memory Usage 1,812KB
  • 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
  • (4)bbcode_php_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete