vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Dynamic Announcements: Programmable Forum Home Announcement/Message with conditionals (https://vborg.vbsupport.ru/showthread.php?t=64189)

CyberRanger 09-02-2005 10:06 AM

Love this hack! I now have the message showing in my OT area only:
http://www.strategyzoneonline.com/fo...play.php?f=161

But, check this out:
http://www.strategyzoneonline.com/fo...ad.php?t=30396
In this one thread, the default Dynamic Announcement seems to have been inserted as the message for a number of the posts. I'm baffled!

Logician 09-02-2005 10:12 AM

Quote:

Originally Posted by westpointer
Love this hack! I now have the message showing in my OT area only:
http://www.strategyzoneonline.com/fo...play.php?f=161

But, check this out:
http://www.strategyzoneonline.com/fo...ad.php?t=30396
In this one thread, the default Dynamic Announcement seems to have been inserted as the message for a number of the posts. I'm baffled!

I'm reported this bug a few times before but it just happens (infrequently, not always) if you hack the hack to apply it to global.php. I don't use the hack this way and I suggest using it as its original release (as a forum home announcement only) so I didn't trace the roots of this problem.

Edit : Turning off post caching (vb admin cp/options) may help. Give it a shot!

CyberRanger 09-02-2005 10:54 AM

Quote:

Originally Posted by Logician
I'm reported this bug a few times before but it just happens (infrequently, not always) if you hack the hack to apply it to global.php....
Edit : Turning off post caching (vb admin cp/options) may help. Give it a shot!

Okay, I'm not that familiar with the impact of turning off post caching. Would that have other adverse effects?

BTW - the problem is very interesting. If I look in the post table, the correct text IS present for the post in question. So ... where in the world is it pulling that text from??? I don't have that in my announcements anymore. Time to poke around some more. I like having this in global.php so I'd rather find the cause.

Thanks for the very quick reply!

Edit - hmm, the problem is in post_parsed. 26 records have "Hello Unregistered! Welcome to our board!" in the pagetext_html field. A rebuild of the post cache (via the AdminCP) fixed the problem.

BRC2 09-04-2005 07:00 AM

Great hack! Is there a way to specifically exclude spiders from seeing the "guests" annoucement messages?

Thanks,
Brian

David_R 09-04-2005 06:10 PM

Quote:

Originally Posted by westpointer
Okay, I'm not that familiar with the impact of turning off post caching. Would that have other adverse effects?

BTW - the problem is very interesting. If I look in the post table, the correct text IS present for the post in question. So ... where in the world is it pulling that text from??? I don't have that in my announcements anymore. Time to poke around some more. I like having this in global.php so I'd rather find the cause.

Thanks for the very quick reply!

Edit - hmm, the problem is in post_parsed. 26 records have "Hello Unregistered! Welcome to our board!" in the pagetext_html field. A rebuild of the post cache (via the AdminCP) fixed the problem.

did you got a working solution to fix the problem, when dynamic annoucements are added to global.php ?
Rebuilding post_cache fixed the problem temprarily only. :(

ragintajin 09-19-2005 10:35 PM

Any plans for a VB3.5 update?

SirJonathan 09-22-2005 12:48 AM

I'd LOVE to have this again for vB 3.5 :)!

Logician 09-25-2005 08:47 AM

I need a few beta testers for 3.5 version. Anybody interested please email me.

I need someone who is:
* Already using this hack in vb 3.0 version and familiar with the hack
* Already upgraded his board to 3.5 (latest version ie RC3) or at least has a test 3.5 enviroment to test the hack.
* Ready to install the hack to his board (or test board)
* Let me know the results adn give me feedback

Please contact me via PM or email and let me know your email adress if you meet ALL the conditions above and I'll send you the hack.

3.5 version is coded as a pluggin so it does not require you to hack your vb codes. You can easily install it through vb3.5 pluggin system and can also uninstall/disable it with 1 click.

I've tested it in my localhost and it works fine but my own board is not upgraded to 3.5 yet, so I want to get a few confirmations from others before releasing the hack officially.

Thanks!

Kihon Kata 09-25-2005 01:16 PM

I am already running RC3 here with this hack working just fine ;) WINK! lol



Quote:

Originally Posted by Logician
I need a few beta testers for 3.5 version. Anybody interested please email me.

I need someone who is:
* Already using this hack in vb 3.0 version and familiar with the hack
* Already upgraded his board to 3.5 (latest version ie RC3) or at least has a test 3.5 enviroment to test the hack.
* Ready to install the hack to his board (or test board)
* Let me know the results adn give me feedback

Please contact me via PM or email and let me know your email adress if you meet ALL the conditions above and I'll send you the hack.

3.5 version is coded as a pluggin so it does not require you to hack your vb codes. You can easily install it through vb3.5 pluggin system and can also uninstall/disable it with 1 click.

I've tested it in my localhost and it works fine but my own board is not upgraded to 3.5 yet, so I want to get a few confirmations from others before releasing the hack officially.

Thanks!


Logician 09-25-2005 01:38 PM

Quote:

Originally Posted by TonysDesigns
I am already running RC3 here with this hack working just fine ;) WINK! lol

Great! Yet you are running it as a "code modification" (ie hack), however 3.5 version I ported runs as a pluggin so it is manageable through your admin cp/products section and can be installed without modifying vb code. ;)

digitalSite 09-26-2005 05:20 AM

HI:

Everything was working fine...until i moved a usergroup over to another usergroup and deleted the original usergroup. I updated the Dynamic thingy to replect the new usergroup's id. However, it doesn't seem to work anymore, like it I never installed the hack! I still see the templates there, and I still see the modofied files...does anyone have any idea what happened?

I am using:

[[($bbuserinfo[userid]==2)]]This is a test.[[/($bbuserinfo[userid]==2)]]

Thanks...

UPDATE: HA! Nevermind...it's 2:22AM and I copied /pasted from Logician's tutorial to "make sure i have the correct conditional" but I FORGOT to add the word "group" so that the correct code is:

[[($bbuserinfo[usergroupid]==2)]]This is a test.[[/($bbuserinfo[usergroupid]==2)]]

To reflect the USERGROUP and not just the USER!!! :D

Goodnight all!
Thanks for this cool hack!

Takamine334 09-27-2005 03:55 AM

I can't close the pop up menu...something I did wrong?

David_R 09-28-2005 10:43 AM

Quote:

Originally Posted by David_R
did you got a working solution to fix the problem, when dynamic annoucements are added to global.php ?
Rebuilding post_cache fixed the problem temprarily only. :(

can someone help me fix my problem please

Logician 09-28-2005 05:13 PM

The hack for vb version 3.5 released here:
https://vborg.vbsupport.ru/showthread.php?t=97073

Takamine334 09-30-2005 11:43 PM

anyone know why in Firefox the popup is huge and why when I click close, the box doesn't go away?

TundraSoul 10-05-2005 04:36 AM

Is there was way to display information from the userfield table? eg. $userfield[field18]==

Logician 10-05-2005 06:09 AM

Quote:

Originally Posted by TundraSoul
Is there was way to display information from the userfield table? eg. $userfield[field18]==

$bbuserfield[field18] should work if it is an inputbox

TundraSoul 10-05-2005 06:25 AM

I'm trying to get this to work. It basically opens the message if their field is empty.

[[($bbuserinfo[usergroupid]==6 AND $bbuserfield[field18]==)]]Hello $bbuserinfo[username], please take a moment to update your user profile with your current information. Click the user CP link above, and then click Edit Profile. [[/($bbuserinfo[usergroupid]==6 AND $bbuserfield[field18]==)]]

Logician 10-05-2005 06:28 AM

Quote:

Originally Posted by TundraSoul
I'm trying to get this to work. It basically opens the message if their field is empty.

[[($bbuserinfo[usergroupid]==6 AND $bbuserfield[field18]==)]]Hello $bbuserinfo[username], please take a moment to update your user profile with your current information. Click the user CP link above, and then click Edit Profile. [[/($bbuserinfo[usergroupid]==6 AND $bbuserfield[field18]==)]]

[[($bbuserinfo[usergroupid]==6 AND !$bbuserfield[field18])]]Hello $bbuserinfo[username], please take a moment to update your user profile with your current information. Click the user CP link above, and then click Edit Profile. [[/($bbuserinfo[usergroupid]==6 AND !$bbuserfield[field18])]]

Boofo 10-05-2005 06:50 AM

Wouldn't this also work, Sinan?

Quote:

AND $bbuserfield[field18]== ''

Logician 10-05-2005 12:49 PM

Quote:

Originally Posted by Boofo
Wouldn't this also work, Sinan?

It would.. But his message was lacking ''

TundraSoul 10-05-2005 11:31 PM

Thanks, I tried that but it didn't work.

Quote:

Originally Posted by Logician
[[($bbuserinfo[usergroupid]==6 AND !$bbuserfield[field18])]]Hello $bbuserinfo[username], please take a moment to update your user profile with your current information. Click the user CP link above, and then click Edit Profile. [[/($bbuserinfo[usergroupid]==6 AND !$bbuserfield[field18])]]


Logician 10-06-2005 05:02 AM

Quote:

Originally Posted by TundraSoul
Thanks, I tried that but it didn't work.

You are trying with an admin account whose field18 is empty right? Because the conditional is set so.

TundraSoul 10-06-2005 06:08 PM

Correct, I tested it on myself first, and field 18 was empty. I even looked into the database to make sure the option cleared it.

Quote:

Originally Posted by Logician
You are trying with an admin account whose field18 is empty right? Because the conditional is set so.


reismarktq2 10-15-2005 03:32 PM

Need a little help with a conditional:

We currently have our boards set up so that new accounts must go through moderation before they can post, but right now the only way to tell whether there are accounts waiting for moderation is to log into the admin control panel (which I don't want the administrators to have to do every time).

So what I'm asking is, is it possible to set up a conditional that displays when an administrator views the front page AND there are people in the "waiting moderation" group? I have this so far:

[[(($bbuserinfo[usergroupid]==6) AND (!empty(insert conditional that checks for people in usergroup 4)))]]

Logician 10-16-2005 06:06 AM

Quote:

Originally Posted by reismarktq2
Need a little help with a conditional:

We currently have our boards set up so that new accounts must go through moderation before they can post, but right now the only way to tell whether there are accounts waiting for moderation is to log into the admin control panel (which I don't want the administrators to have to do every time).

So what I'm asking is, is it possible to set up a conditional that displays when an administrator views the front page AND there are people in the "waiting moderation" group? I have this so far:

[[(($bbuserinfo[usergroupid]==6) AND (!empty(insert conditional that checks for people in usergroup 4)))]]

nope sorry, this is not possible without modification of the hack

reismarktq2 10-21-2005 02:13 AM

Quote:

Originally Posted by Logician
nope sorry, this is not possible without modification of the hack

Anyone have any idea how I would do this modification?

gigaenvy 10-24-2005 10:49 PM

Any chance to make a random or rotating announcement?

Crazy Serb 10-26-2005 03:41 AM

ok, what's the suntax for checking if the users are NOT members of 2 secondary usergroups, but are members of any other primary group?

I've tried the below without any success (or I might have done something wrong along the way):

Code:

[[(!$bbuserinfo[membergroupids]==9 AND !$bbuserinfo[membergroupids]==12)]]
content
[[(!$bbuserinfo[membergroupids]==9 AND !$bbuserinfo[membergroupids]==12)]]


Logician 10-26-2005 06:51 AM

Quote:

Originally Posted by Crazy Serb
ok, what's the suntax for checking if the users are NOT members of 2 secondary usergroups, but are members of any other primary group?

I've tried the below without any success (or I might have done something wrong along the way):

Code:

[[(!$bbuserinfo[membergroupids]==9 AND !$bbuserinfo[membergroupids]==12)]]
content
[[(!$bbuserinfo[membergroupids]==9 AND !$bbuserinfo[membergroupids]==12)]]


[[(!is_member_of($bbuserinfo,9 ,12))]]
content
[[/(!is_member_of($bbuserinfo,9 ,12))]]

Crazy Serb 10-26-2005 07:13 AM

Quote:

Originally Posted by Logician
[[(!is_member_of($bbuserinfo,9 ,12))]]
content
[[/(!is_member_of($bbuserinfo,9 ,12))]]


tried that, didn't get anything now... no popup.

Logician 10-26-2005 07:18 AM

Quote:

Originally Posted by Crazy Serb
tried that, didn't get anything now... no popup.

This conditional means the user shouldn't be a member of usergroup 9 OR 12. This applies to both primary usergroup AND additional usergroups. So are you trying with a test account which does not belong to 9 and 12 at all?

heynurse 10-26-2005 07:31 AM

I want to show the announcement to everyone, except these user groups: 5,6,7,22

any help?

Logician 10-26-2005 07:37 AM

Quote:

Originally Posted by heynurse
I want to show the announcement to everyone, except these user groups: 5,6,7,22

any help?

[[(!is_member_of($bbuserinfo,5 ,6 ,7, 22))]]
I want to show the announcement to everyone, except these user groups: 5,6,7,22
[[/(!is_member_of($bbuserinfo,5 ,6 ,7, 22))]]

heynurse 10-26-2005 07:50 AM

Quote:

Originally Posted by Logician
[[(!is_member_of($bbuserinfo,5 ,6 ,7, 22))]]
I want to show the announcement to everyone, except these user groups: 5,6,7,22
[[/(!is_member_of($bbuserinfo,5 ,6 ,7, 22))]]

Hi Logician,
Thanks for your prompt reply, I tried the the above conditional and nothing shows up? Thanks

Logician 10-26-2005 08:06 AM

ok, I checked and you both are right. Apparently the check works just for the primary usergroup. So you can use that one if you want to check primary usergroup of the user:

[[(in_array($bbuserinfo[usergroupid], array(5,6,7,22)))]]
show if visitor's primary usergroup is 5 or 6 or 7 or 22
[[/(in_array($bbuserinfo[usergroupid], array(5,6,7,22)))]]

OR

[[(!in_array($bbuserinfo[usergroupid], array(5,6,7,22)))]]
show if visitor's primary usergroup is NOT 5 or 6 or 7 or 22
[[/(!in_array($bbuserinfo[usergroupid], array(5,6,7,22)))]]

I have no suggestion if you want to check secondary usergroup, sorry about it.

Mastar 11-20-2005 02:09 PM

I've upgraded from 3.09 to 3.51 and I would like to know how to remove this hack from the vbulleting options?

Logician 11-20-2005 03:10 PM

Quote:

Originally Posted by Mastar
I've upgraded from 3.09 to 3.51 and I would like to know how to remove this hack from the vbulleting options?

https://vborg.vbsupport.ru/showpost....7&postcount=38


All times are GMT. The time now is 07:47 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.01847 seconds
  • Memory Usage 1,840KB
  • 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
  • (2)bbcode_code_printable
  • (21)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (38)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