vb.org Archive

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

Logician 09-25-2002 08:09 AM

Quote:

Originally posted by LawnDawg
[edit]Is there any way I could add this into my "header" template? does seem to work.. [/edit]
I havent tested it with header template but I cant see a reason it wouldnt work. Just make sure you delete the code from index.php and add it to global.php as mentioned in the install instructions.. Not tested, should work though..

But if you need to use conditional power inside your header template (or any other template) I suggest you checking my Advanced Templates hack either..(Please find it in my profile). You can set conditionals inside your header (or any other template) and if you want you can set announements there too..

2 methods, choose your pick! ;)

RayMatrix 09-25-2002 04:40 PM

. . .but got this Error Message:

Warning: Failed opening '/home/ish/install.php' for inclusion (include_path='.:/usr/share/php') in Unknown on line 0

This comes up when running the DFHA_install.php

The File ist in the Board root Folder, the Board work and its php4.1.x installed.

Any Ideas ?

Willard Reece 09-25-2002 05:19 PM

RayMatrix
permissions for that folder and file?
Do you have that dir and or file chd to 777 so you can run it.
If its not, then it will do that too.

RayMatrix 09-25-2002 07:24 PM

. . .thats it. . .the simplest things are most time the hardest :paranoid:

THANKS !!

PIMPY 09-29-2002 02:56 AM

You maze me yet again Logi, I now have three of your additions on my forums, Currently i'm trying to get them integrated and working, but they are on and working.

Only questions I have are..

Simple: How can I find the usergroup IDs? (i'm sure its very simple and I'm sure I could just create a small bit of PHP to tell me, but hey, why screw up when ya'll are so smart)

and two..

Would it be possible to somehow get more conditionals working at one time? I know you say it can't be done in all of your readmes, but I'm sure there is a way for it to parse each thing not just do one then stop. I havn't looked but I'm assuming that the general code is similar to
If conditional1 is true end, else goto next bit

but could it be possible to do

if conditional1 is true display, now do conditional2, and so on

yes good 'ol PSEUDO

because currently how I plan to do it willl be have one conditional with all things i want in it, plus everything else, then another conditional for some thigns already in the other and so on, but that takes SOO much time, and is SOO un-efficiant. Theres gotta be someway we cna make it so it parses every conditional no matter what.


Edit: OK, now i was thinking that considering most code in the php files around everywhere, its along the lines of

If Blah
elseif blah
elseif blah

so really maybe it just should be

if blah;
if blah;
if blah;

then each conditional is parsed and used no matter what

little bit of editing needed so that all things appear in one box and not in 4 or 5 :P

Logician 09-29-2002 10:00 AM

Quote:

How can I find the usergroup IDs?
This will help..

Quote:

if conditional1 is true display, now do conditional2, and so on
Before trying to modify this hack I suggest you first checking Advanced Templates Hack. It has the same conditional power (now for vb templates) and its parsing is just like you want: It parse through the entire template and parse all met conditionals, does not return when found a first true conditional. So you can use it for your needs, say, by creating conditionals in your forumhome template and putting inside your announcement and its HTML code. All of them will be displayed if condition is true..

The General 09-29-2002 12:01 PM

Cheers mate!

VeryVERY cool hack, works like a charm on 2.2.8!

Wildthinks 10-09-2002 08:20 AM

[[($bbuserinfo[usergroupid]==6 OR $bbuserinfo[usergroupid]==7)]]
Hi $bbuserinfo[usergroupid],
diese Nachricht k?nnen nur Moderatoren und Admins lesen. Bitte einen Thread im Mod-Board aufmachen oder in einem Antworten, ob Du das lesen kannst :umfall:
Gr??e Wildthinks
[[/($bbuserinfo[usergroupid]==6 OR $bbuserinfo[usergroupid]==7)]]

The "Hi $bbuserinfo[usergroupid]," are on screen and not "Hi Wildthinks" :confused:

Logician 10-09-2002 04:55 PM

Quote:

Originally posted by Wildthinks
[[($bbuserinfo[usergroupid]==6 OR $bbuserinfo[usergroupid]==7)]]
Hi $bbuserinfo[usergroupid],
diese Nachricht k?nnen nur Moderatoren und Admins lesen. Bitte einen Thread im Mod-Board aufmachen oder in einem Antworten, ob Du das lesen kannst :umfall:
Gr??e Wildthinks
[[/($bbuserinfo[usergroupid]==6 OR $bbuserinfo[usergroupid]==7)]]

The "Hi $bbuserinfo[usergroupid]," are on screen and not "Hi Wildthinks" :confused:

Did you see my default text correctly when you installed the hack?

And BTW. you should use "Hi $bbuserinfo[username],", not "$bbuserinfo[usergroupid]" ;)

kira 10-09-2002 07:56 PM

Just wanted to thank you for another great and powerful hack, Logician. Every bit of personalization and customization helps, and as always you've added tremendously to my abilities to control my forum. Thanks!


All times are GMT. The time now is 01:45 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.01338 seconds
  • Memory Usage 1,747KB
  • 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_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (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