View Full Version : Best way to hide guest welcome header on certain style
pjkcards
12-19-2011, 04:00 PM
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!
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 :) ).
pjkcards
09-17-2012, 09:19 PM
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!
Stefan118
09-17-2012, 10:12 PM
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.
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.
...
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.
pjkcards
09-24-2012, 05:59 PM
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.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.