Register Members List Search Today's Posts Mark Forums Read

Reply
 
Article Options
  #211  
Old 08 Jun 2011, 15:36
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Real name: Lynne
Originally Posted by baghdad4ever View Post
hi

how to display Google ads to the guest and in home page only?
Assuming your "home page" is the forum.php page....

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

__________________
Former vBulletin.org Staff Member

Try a search before posting for help. Many users won't, and don't, help if the question has been answered several times before.
W3Schools -
Online vBulletin Manual
If I post some CSS and don't say where it goes, put it in the additional.css template.
I will NOT help via PM (you will be directed to post in the forums for help.)

Last edited by Lynne; 08 Jun 2011 at 22:45. Reason: corrected ==
Reply With Quote
  #212  
Old 08 Jun 2011, 19:10
baghdad4ever baghdad4ever is offline
 
Join Date: May 2007
Real name: husam
Originally Posted by Lynne View Post
Assuming your "home page" is the forum.php page....

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

thanks lynne

but this will occur


Warning: Invalid argument supplied for foreach() in [path]/includes/functions.php on line 3416

The following error occurred when attempting to evaluate this template:
%1$s
This is likely caused by a malformed conditional statement. It is highly recommended that you fix this error before continuing, but you may continue as-is if you wish
Reply With Quote
  #213  
Old 08 Jun 2011, 22:03
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
Change the = to == and try again.
__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
  #214  
Old 11 Jun 2011, 15:02
ChromeDome ChromeDome is offline
 
Join Date: Dec 2010
How can I create a condition based on "Social Groups" (no user groups)? I tried this but it didn't work:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

__________________
http://www.ChromebookUser.com
Reply With Quote
  #215  
Old 11 Jun 2011, 15:30
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
Where are you trying to use this conditional?
__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
  #216  
Old 11 Jun 2011, 16:09
ChromeDome ChromeDome is offline
 
Join Date: Dec 2010
I want to use it in the footer template.

My site uses a floating tool bar. For members that want to hide the tool bar all together, I want to allow them to add themselves to the social group, "Hide Tool Bar". I then want to use the conditional to hide the tool bar code if the user is a member of this social group.
__________________
http://www.ChromebookUser.com
Reply With Quote
  #217  
Old 11 Jun 2011, 17:29
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
Originally Posted by ChromeDome View Post
I want to use it in the footer template.

My site uses a floating tool bar. For members that want to hide the tool bar all together, I want to allow them to add themselves to the social group, "Hide Tool Bar". I then want to use the conditional to hide the tool bar code if the user is a member of this social group.
Ahh... OK, well that will never work with social groups.

Luckily however vBulletin has a built in feature, publicly joinable usergroups that should work exactly as you describe.

In your Usergroup manager in Admin CP, make a new usergroup based off of registered users. Set the option to make it a publicly joinable usergroup. Call it "Hidden Toolbar" or whatever.

Members can join it via the User CP -> Group Memberships

And then you can use the standard condition:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Where X is the usergroup you made.


OR... now that I've typed that out... The "right" way of doing this would be using a Custom Profile Field.

In Admin CP make a New Custom Profile Field... Basically a "Yes/No" option to turn on/off the toolbar...

Then you would use a condition like:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Where X is the field # assigned by vBulletin.

I can give you more details on this if you think it will work for your needs.
__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
  #218  
Old 11 Jun 2011, 18:37
ChromeDome ChromeDome is offline
 
Join Date: Dec 2010
I used the custom profile field solution. Thank you so much!!!!
__________________
http://www.ChromebookUser.com
Reply With Quote
  #219  
Old 12 Jun 2011, 18:58
kether1 kether1 is offline
 
Join Date: Jun 2006
Real name: Kether
Is there a conditional to use if one would like to show something only to the member who posted the post?

For example:
I created a custom field that I would like for the member to enter information into that s/he and the admin can see when posted, but no other members can see. (A secure field - if you will).

Thanks,
Kether
Reply With Quote
  #220  
Old 12 Jun 2011, 19:11
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
You could do a condition to show code only to the user who posted it...


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

(will work in the postbit)


But you'd still need to make the extra field to hold the data and everything else needed to process it. The conditional is the easy part.
__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
  #221  
Old 12 Jun 2011, 19:19
kether1 kether1 is offline
 
Join Date: Jun 2006
Real name: Kether
Originally Posted by BirdOPrey5 View Post
You could do a condition to show code only to the user who posted it...


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

(will work in the postbit)


But you'd still need to make the extra field to hold the data and everything else needed to process it. The conditional is the easy part.
Thanks Joe. I was able to create the extra field, just couldn't figure out how to show it's contents only to the member who posted and admin instead of everyone who could see the post.

I will give you code a go. Thanks for your quick help. I appreciate it very much.

Kether

--------------- Added 13 Jun 2011 at 14:51 ---------------

Originally Posted by kether1 View Post
Thanks Joe. I was able to create the extra field, just couldn't figure out how to show it's contents only to the member who posted and admin instead of everyone who could see the post.

I will give you code a go. Thanks for your quick help. I appreciate it very much.

Kether

Well, I am still having trouble getting this to work. I guess I need a conditional to show a field only to the admin user group and the individual who posted the information.

So, I use the following code to identify a field, but need help with the conditional to make it only be seen by the admin group and the individual who posted the information:

<vb:if condition="$field['fieldid'] == 6">

Any suggestions? Thanks again.
Kether

Last edited by kether1; 13 Jun 2011 at 14:51. Reason: Auto-Merged DoublePost
Reply With Quote
  #222  
Old 13 Jun 2011, 19:17
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
The important thing about the conditional I gave you is it only works in posts/the postbit.

You could show it to admins OR the user who's viewing his own post with:



Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Where 6 is the usual usergroup for admins.

But the fact your mentioning fields makes me think this code isn't for the postbit.

If you're using custom profile fields you can mark them as private to limit who sees them.
__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
  #223  
Old 13 Jun 2011, 19:29
kether1 kether1 is offline
 
Join Date: Jun 2006
Real name: Kether
Originally Posted by BirdOPrey5 View Post
The important thing about the conditional I gave you is it only works in posts/the postbit.

You could show it to admins OR the user who's viewing his own post with:



Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Where 6 is the usual usergroup for admins.

But the fact your mentioning fields makes me think this code isn't for the postbit.

If you're using custom profile fields you can mark them as private to limit who sees them.

No actually, I am editing the SHOWENTRY template in vbadvanced dynamics. I have added custom fields and would like to specify who can see one or two specific private fields. Sorry I did not make that clear in the first place.

The bit of code I put in my previous 'merged' post:

<vb:if condition="$field['fieldid'] == 6">

Tells the forum to put the information in field 6 in that location in the SHOWENTRY. I want to wrap a conditional around it to only display the information in field '6' to the admin group and the person who actually posted the information in the first place.

I believe it should be fairly simple to wrap a conditional around this conditional, but so far I have not been able to figure it out.

Thanks for your response.

Kether
Reply With Quote
  #224  
Old 13 Jun 2011, 19:42
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
 
Join Date: Jun 2008
Real name: Joe D.
Originally Posted by kether1 View Post
No actually, I am editing the SHOWENTRY template in vbadvanced dynamics. I have added custom fields and would like to specify who can see one or two specific private fields. Sorry I did not make that clear in the first place.

The bit of code I put in my previous 'merged' post:

<vb:if condition="$field['fieldid'] == 6">

Tells the forum to put the information in field 6 in that location in the SHOWENTRY. I want to wrap a conditional around it to only display the information in field '6' to the admin group and the person who actually posted the information in the first place.

I believe it should be fairly simple to wrap a conditional around this conditional, but so far I have not been able to figure it out.

Thanks for your response.

Kether
Well this will limit it to administrators but I would have no way of knowing the conditional vbadvanced dynamics might use to know which user posted it- that would be a question better asked at their own forums- they'll know what's possible with their product.


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

The combined code, assuming you can find a conditional from vb advanced would be something like:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

__________________
-Joe
Former vb.org Moderator. Retired.

@BirdOPrey5 | All Things BOP5 | Joe's Ultimate Off Topic
Note - I no longer making new VB mods, sorry.
Reply With Quote
  #225  
Old 13 Jun 2011, 20:38
Bisha's Avatar
Bisha Bisha is offline
 
Join Date: Mar 2006
Why, this code is now working for me on postbit_legacy template:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

I get only OFFLINE :S even the user is online.

Last edited by Bisha; 13 Jun 2011 at 20:43.
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 2 (0 members and 2 guests)
 
Article Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 11:12.

Layout Options | Width: Wide Color: