Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 12-19-2011, 04:00 PM
pjkcards pjkcards is offline
 
Join Date: Jul 2007
Posts: 299
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Best way to hide guest welcome header on certain style

I'd like to hide the "default_guest_message" notice from just 1 style (the mobile style). What is the best way of doing this?

Can I put conditionals in the notice itself, or is there a better way?

Thanks!
Reply With Quote
  #2  
Old 12-19-2011, 11:05 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You can't put conditionals in a notice (or at least it didn't seem to work for me), and there doesn't seem to be any way to negate a condition. I did try setting up a blank notice for that style and then setting the existing guest notice to show if criteria didn't match my blank notice, but then I got a blank yellow box.

Anyway, I already had this product that adds a "day of week" criteria to notices, so I threw in a few lines to add a "user is browsing using style other than..." criteria which I think will do what you want. I'm attaching it here (I may get around to releasing it some day ).
Attached Files
File Type: xml product-kh99_additional_notice_cr.xml (4.8 KB, 5 views)
Reply With Quote
  #3  
Old 09-17-2012, 09:19 PM
pjkcards pjkcards is offline
 
Join Date: Jul 2007
Posts: 299
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by kh99 View Post
You can't put conditionals in a notice (or at least it didn't seem to work for me), and there doesn't seem to be any way to negate a condition. I did try setting up a blank notice for that style and then setting the existing guest notice to show if criteria didn't match my blank notice, but then I got a blank yellow box.

Anyway, I already had this product that adds a "day of week" criteria to notices, so I threw in a few lines to add a "user is browsing using style other than..." criteria which I think will do what you want. I'm attaching it here (I may get around to releasing it some day ).
Thanks for the reply. I know this is old, it got burried at the bottom of my to-do list.

I installed this product. I can't find a way to configure it for my mobile style. Where are the configuration options? How can I actually use this?

Thanks!
Reply With Quote
  #4  
Old 09-17-2012, 10:12 PM
Stefan118 Stefan118 is offline
 
Join Date: Dec 2010
Location: Vaassen (Netherlands)
Posts: 299
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You could also copy the default guest message and create the same message in a new notice.
Then you select: User is browsing using style
to the style you DO want to show the message.
For instance, you have 3 styles and a mobile style.
Then you create 3 the same default guest messages, and set every notice to an other style.
That way your mobile style is the only style it doesn't show the message.

Not the best way probably, but the most simple solution.
Reply With Quote
  #5  
Old 09-18-2012, 02:04 AM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by pjkcards View Post
Thanks for the reply. I know this is old, it got burried at the bottom of my to-do list.

I installed this product. I can't find a way to configure it for my mobile style. Where are the configuration options? How can I actually use this?
All the options added by this mod show up when editing a notice. You should now have a "User is browsing using style other than..." choice in the list of notice criteria.

BTW, I did actually release this here: https://vborg.vbsupport.ru/showthread.php?t=277022 , and there's a screen grab showing the added options.
So, go to the notices manager, edit the default guest message, check the box next to "User is browsing using style other than", and select your mobile style from the drop down menu.


Quote:
Originally Posted by Stefan118 View Post
...
Not the best way probably, but the most simple solution.
That is a good point. When I originally read this thread I assumed that pjkcards knew it could be done that way but was asking about a way to avoid creating the same notice multiple times, but maybe I should have pointed that out before suggesting a mod.
Reply With Quote
  #6  
Old 09-24-2012, 05:59 PM
pjkcards pjkcards is offline
 
Join Date: Jul 2007
Posts: 299
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks guys, I appreciate it. I didn't know about either of those options, but the hack provided works great.

Thanks again for your time.
Reply With Quote
Reply


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

Forum Jump


All times are GMT. The time now is 01:59 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.03778 seconds
  • Memory Usage 2,228KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (6)post_thanks_box
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit_info
  • (6)postbit
  • (1)postbit_attachment
  • (6)postbit_onlinestatus
  • (6)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_attachment
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete