vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   Dynamic Announcements: Programmable Forum Home Announcement/Message with conditionals (https://vborg.vbsupport.ru/showthread.php?t=97073)

ShadowOne 11-19-2005 11:14 AM

is it possible for you to add some options in the admincp?
like where you can type in a username to send it to or the user number...
And Maybe Have It Seperated By Commas(,), so i can put more than one username or number, like to send it to lets say 16 people....but only one time or whenever i need to...
or just click a radio button or something providing which usergroup you want it to be sent out to....
and maybe have a radio button for guests too...

Logician 11-19-2005 11:48 AM

Quote:

Originally Posted by ShadowOne
is it possible for you to add some options in the admincp?
like where you can type in a username to send it to or the user number...
And Maybe Have It Seperated By Commas(,), so i can put more than one username or number, like to send it to lets say 16 people....but only one time or whenever i need to...
or just click a radio button or something providing which usergroup you want it to be sent out to....
and maybe have a radio button for guests too...

You can point users with their userid

[[($bbuserinfo[userid]==1 OR $bbuserinfo[userid]==1)]]
Show this announcement if user id is 1 or 2
[[/($bbuserinfo[userid]==1 OR $bbuserinfo[userid]==1)]]

Logician 11-19-2005 11:48 AM

Quote:

Originally Posted by lulala
[[($bbuserinfo[lastvisit] and $bbuserinfo[lastvisit] < strtotime("-7days"))]]
Show this announcement if page visitor has not visited my board for over 7 days
[[/($bbuserinfo[lastvisit] and $bbuserinfo[lastvisit] < strtotime("-7days"))]]

Is It Correct as above?
I cannot show it... :ermm:

put space between -7 and days

Logician 11-19-2005 11:52 AM

Quote:

Originally Posted by lulala
Popup Frequency Unit is Hour
Can change to Second or minute??

edit pluggin "Dynamic Forum Home Announcement Hack by Logician" at "forumhome_complete"

find:
PHP Code:

        if ($vbulletin->userinfo[lastactivity] > AND $vbulletin->userinfo[lastactivity] > mktime (date("H")-$vbulletin->options[dynamic_pop_freq], date("i"), date("s"), date("m"), date("d"), date("Y")))     //popup once in every XX hours 

replace it as:

PHP Code:

        if ($vbulletin->userinfo[lastactivity] > AND $vbulletin->userinfo[lastactivity] > mktime (date("H"), date("i")-$vbulletin->options[dynamic_pop_freq], date("s"), date("m"), date("d"), date("Y")))     //popup once in every XX hours 

Save it.

Now it is minutes

ShadowOne 11-19-2005 11:55 AM

Quote:

Originally Posted by Logician
You can point users with their userid

[[($bbuserinfo[userid]==1 OR $bbuserinfo[userid]==1)]]
Show this announcement if user id is 1 or 2
[[/($bbuserinfo[userid]==1 OR $bbuserinfo[userid]==1)]]


well i was trying to see if you could somehow add what i suggested? :ermm:

lulala 11-19-2005 12:19 PM

Quote:

Originally Posted by Logician
put space between -7 and days

I tried what you say,but the same

It not work.... :disappointed:

lulala 11-19-2005 12:24 PM

It's work....YAYA
I used this variable "$bbuserinfo[lastactivity]"
[[($bbuserinfo[lastactivity] and $bbuserinfo[lastactivity] < strtotime("-7days"))]]
Show this announcement if page visitor has not visited my board for over 7 days
[[/($bbuserinfo[lastactivity] and $bbuserinfo[lastactivity] < strtotime("-7days"))]]

Logician 11-19-2005 04:44 PM

Quote:

Originally Posted by lulala
It's work....YAYA
I used this variable "$bbuserinfo[lastactivity]"
[[($bbuserinfo[lastactivity] and $bbuserinfo[lastactivity] < strtotime("-7days"))]]
Show this announcement if page visitor has not visited my board for over 7 days
[[/($bbuserinfo[lastactivity] and $bbuserinfo[lastactivity] < strtotime("-7days"))]]

When you use lastactivity, the conditional checks his last forum visit date, not last post date.

lulala 11-19-2005 06:34 PM

Quote:

Originally Posted by Logician
When you use lastactivity, the conditional checks his last forum visit date, not last post date.

Ya,it 's i need.
Could you show how to
show an announcement in user's birthday?
What is user's birthday of conditional syntax?
$bbuserinfo[birthday] ?
I want to show "Happy Birthday" to User?

Brandon Sheley 11-20-2005 05:04 PM

Quote:

Originally Posted by Logician
[[($bbuserinfo[userid] AND $bbuserinfo[posts]<5)]]
Hello $bbuserinfo[username] pls post more :D
[[($bbuserinfo[userid] AND $bbuserinfo[posts]<5)]]

Translation :

If visitor is a user but has less than 5 posts, say :

Hello $bbuserinfo[username] pls post more :D


thank you :D

lulala 11-20-2005 05:22 PM

[[($bbuserinfo[birthday] and $bbuserinfo[birthday] == strtotime("0 days"))]]
Show this announcement if today is page visitor's birthday
[[/($bbuserinfo[birthday] and $bbuserinfo[birthday] == strtotime("0 days")]]

Is it Correct?
:disappointed:

dc3dreamer 11-22-2005 03:23 PM

Awesome! I have this working under VB 3.5.1.

I did alter it, however. I didn't like the announcement in its own box/table, so instead I edited my style FORUMHOME templates to put the announcement text into the "guest" announcement area, and removed the <if condition="$show['guest']">...</if> so that area always shows. I did not add the $dfh_announcement after $navbar. Instead, I replaced the first_visit_message phrase code with $dfh_announcement_announcementtopaste. Voila! I then used conditionals in the DFHA to control whether my guest message or my registered user message is displayed there.

Fine point: I did actually add a new phrase welcome_to_the_x_dfha and switch between that and welcome_to_the_x depending on whether $show['guest'] is true or false. That way the title of the announcement area changes between guests and registered users. I didn't post the code here because it's different in VB Classic vs Surge, etc. I can post the Classic code if needed.

Now the display is consistent with the current style, takes up less room, and is really configurable. All you do is edit the DFHA announcement text in the condiitional blox.

dc3dreamer 11-22-2005 03:30 PM

One thing that got me: You cannot nest conditionals. I might look at your system to see if it can recursively call itself to parse nested conditionals. For me at least, it would be very helpful. I use conditionals to switch between guest and registered user messages, and I can't use any condiitionals inside those. Instead I have to make a rather messy set of linear conditionals for all of the permutations of conditions I have.

Also the conditional syntax is a bit klunky, but I understand it's code you've had for a long ime. If it ain't broke, don't fix it!

Logician 11-22-2005 03:34 PM

Quote:

Originally Posted by dc3dreamer
One thing that got me: You cannot nest conditionals. I might look at your system to see if it can recursively call itself to parse nested conditionals. For me at least, it would be very helpful. I use conditionals to switch between guest and registered user messages, and I can't use any condiitionals inside those. Instead I have to make a rather messy set of linear conditionals for all of the permutations of conditions I have.

Also the conditional syntax is a bit klunky, but I understand it's code you've had for a long ime. If it ain't broke, don't fix it!

Sorry, nested conditionals is not possible in the system.

dc3dreamer 11-22-2005 03:55 PM

Update #2 (final!): All is well now. Here is the code for dynamic_a() which implements nested conditionals:
Code:

function dynamic_a($logician_dfa_incoming1)
{
    extract ($GLOBALS);

    // Prevent successive conditionals on separate lines from generating
    // spurious <br /> after running thru BbCode parser. You might not
    // like this, it's optional.
    $logician_dfa_incoming1 = ereg_replace("\]\][\r\n\f \t]*\[\[", "]][[", $logician_dfa_incoming1);
    // Recursively process nested conditionals
    $logician_dfa_incoming1 = trim(dynamic_b($logician_dfa_incoming1));
    // Finish up by running result through BbCode parser
    if (trim($logician_dfa_incoming1))
    {
        $parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list());
        $logician_dfa_incoming1 = $parser->do_parse($logician_dfa_incoming1, 1, 1, 1, 1, 1, 1);
    }
    return $logician_dfa_incoming1;
}

function dynamic_b($dc3dreamer_dfa_incoming1)
{
    extract ($GLOBALS);

    while (preg_match("/\[\[(.*)\]\](.*)\[\[(\/\\1)\]\]/siU", $dc3dreamer_dfa_incoming1, $matches14))
    {
        @eval ('if ('.stripslashes($matches14[1]).') { $eval_deger= "1"; } else { $eval_deger= "0"; }');
        if ($eval_deger == 1)          //if conditional applied, replace with inner text
        {
            $dc3dreamer_dfa_incoming1 = dynamic_b(str_replace($matches14[0], $matches14[2], $dc3dreamer_dfa_incoming1));
        }
        else                            // Conditional not applied, delete the whole chunk
        {
            $dc3dreamer_dfa_incoming1 = dynamic_b(str_replace($matches14[0], '', $dc3dreamer_dfa_incoming1));
        }
    }
    return $dc3dreamer_dfa_incoming1;
}

The recursion continues until there are no conditionals found, at which point the final result is passed through the BbCodeParser at the end of the first method. The trick was to remove line endings from conditionals that follow one another with just newlines between. They generated extra breaks and line spacing after going through the BbCode parser. You might want to remove the * in the regexp for the call to ereg_replace(). Er, do I really have to name my parameter variable like it might exist in the host page? I hope not, but I copied Logician's style. I would have used sumpin' like $src for the parameter var :nervous:

I'm slowly coming up to speed on PHP :nervous: I was killed by the $bbuserinfo[membergroupids] variable testing against values, till my ancient Perl tablets fell out on the ground. Yumba! It can be an array and it may not even exist! Well, rookie me! I got it now.

This is so nice! Nested conditionals open up a whole new world of possibilities, but ... Thank you Logician Thank you Logician Thank you Logician ...

Logician 11-24-2005 05:12 AM

Quote:

Originally Posted by dc3dreamer
Update #2 (final!): All is well now. Here is the code for dynamic_a() which implements nested conditionals:
Code:

function dynamic_a($logician_dfa_incoming1)
{
    extract ($GLOBALS);

    // Prevent successive conditionals on separate lines from generating
    // spurious <br /> after running thru BbCode parser. You might not
    // like this, it's optional.
    $logician_dfa_incoming1 = ereg_replace("\]\][\r\n\f \t]*\[\[", "]][[", $logician_dfa_incoming1);
    // Recursively process nested conditionals
    $logician_dfa_incoming1 = trim(dynamic_b($logician_dfa_incoming1));
    // Finish up by running result through BbCode parser
    if (trim($logician_dfa_incoming1))
    {
        $parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list());
        $logician_dfa_incoming1 = $parser->do_parse($logician_dfa_incoming1, 1, 1, 1, 1, 1, 1);
    }
    return $logician_dfa_incoming1;
}

function dynamic_b($dc3dreamer_dfa_incoming1)
{
    extract ($GLOBALS);

    while (preg_match("/\[\[(.*)\]\](.*)\[\[(\/\\1)\]\]/siU", $dc3dreamer_dfa_incoming1, $matches14))
    {
        @eval ('if ('.stripslashes($matches14[1]).') { $eval_deger= "1"; } else { $eval_deger= "0"; }');
        if ($eval_deger == 1)          //if conditional applied, replace with inner text
        {
            $dc3dreamer_dfa_incoming1 = dynamic_b(str_replace($matches14[0], $matches14[2], $dc3dreamer_dfa_incoming1));
        }
        else                            // Conditional not applied, delete the whole chunk
        {
            $dc3dreamer_dfa_incoming1 = dynamic_b(str_replace($matches14[0], '', $dc3dreamer_dfa_incoming1));
        }
    }
    return $dc3dreamer_dfa_incoming1;
}

The recursion continues until there are no conditionals found, at which point the final result is passed through the BbCodeParser at the end of the first method. The trick was to remove line endings from conditionals that follow one another with just newlines between. They generated extra breaks and line spacing after going through the BbCode parser. You might want to remove the * in the regexp for the call to ereg_replace(). Er, do I really have to name my parameter variable like it might exist in the host page? I hope not, but I copied Logician's style. I would have used sumpin' like $src for the parameter var :nervous:

I'm slowly coming up to speed on PHP :nervous: I was killed by the $bbuserinfo[membergroupids] variable testing against values, till my ancient Perl tablets fell out on the ground. Yumba! It can be an array and it may not even exist! Well, rookie me! I got it now.

This is so nice! Nested conditionals open up a whole new world of possibilities, but ... Thank you Logician Thank you Logician Thank you Logician ...

Thanks for your contribution! I've linked your post in the first post of the thread. :)

lulala 11-26-2005 03:08 AM

Quote:

Originally Posted by lulala
[[($bbuserinfo[birthday] and $bbuserinfo[birthday] == strtotime("0 days"))]]
Show this announcement if today is page visitor's birthday
[[/($bbuserinfo[birthday] and $bbuserinfo[birthday] == strtotime("0 days")]]

Is it Correct?
:disappointed:

Anyone can help me...?... :disappointed:

Logician 11-26-2005 06:49 AM

Quote:

Originally Posted by lulala
Ya,it 's i need.
Could you show how to
show an announcement in user's birthday?
What is user's birthday of conditional syntax?
$bbuserinfo[birthday] ?
I want to show "Happy Birthday" to User?

https://vborg.vbsupport.ru/showpost....&postcount=352

tamborinegal 12-03-2005 11:57 AM

Great hack! Thanks so much Logician :)

pauloo 12-03-2005 01:37 PM

Thanks Logician et merci allan pour ta traduction fr ;)

djjeffa 12-04-2005 11:08 PM

Quote:

Originally Posted by Logician
Nothing.. Please follow these step:
* admin cp/manage products/uninstall Dynamic Forum Home Announcement Hack by Logician
* edit includes/config.php, find:

PHP Code:

?> 

replace this line as:
PHP Code:

// Debug
 
$config['Misc']['debug'] = true
?> 

(and upload to the server)

* login to admin cp, go to vb options/dynamic forum home announcements

* delete all settings and settings group in that page to remove 3.0 settings. (by clicking "delete" next to 2 settings and 1 setting group title)

* Revert your config.php (and upload the server)

* Now install 3.5 version.

i dont see admin uninstall Dynamic Forum Home Announcement Hack by Logician in cp/manage products/

and i dont see "delete" (by clicking "delete" next to 2 settings and 1 setting group title)

could u please help?

akanevsky 12-05-2005 12:11 AM

Umm... I do not really understand the purpose of this hack. Can't this simply be done via templating system?

Logician 12-05-2005 07:08 AM

Quote:

Originally Posted by djjeffa
i dont see admin uninstall Dynamic Forum Home Announcement Hack by Logician in cp/manage products/

and i dont see "delete" (by clicking "delete" next to 2 settings and 1 setting group title)

could u please help?

If you installed 3.5 version, you'll see uninstall in product section. If you installed 3.0.x version and then upgraded your board, you won't see it in product section, because it was not a product in 3.0.x. So if you are trying to remove 3.0.x hack settings in 3.5 follow the message you quoted above.

Quote:

I do not really understand the purpose of this hack. Can't this simply be done via templating system?
Do you understand the purpose of vbulletin setting "Use Legacy (Vertical) Postbit Template"? Can't this simply be done via templating system by overwriting postbit template?

This hack gives you an easy way to put global announcements into your forum home page without dealing with templating system. It also allows you to put popup announcements to your forum homa page without dealing with multiple templates and complicated HTML codes for DHTML layers.

Smiry Kin's 12-17-2005 12:16 PM

anyway to make it smaller? :S very nice work tho! jsut massive!

bashy 12-17-2005 09:43 PM

Hi

I have uploaded the php in the right place...
I have imported the product as a product, checked it 3 times, but cant see it in the manage product list, although when i try to upload it again it says its already there...

Another thing, when i try to edit the forumhome template and click save, it just reverts back to the state it was before the edit...

This is really strange...

Any advice please...

Bashy

Logician 12-18-2005 05:56 AM

Quote:

Originally Posted by bashy
Hi

I have uploaded the php in the right place...
I have imported the product as a product, checked it 3 times, but cant see it in the manage product list, although when i try to upload it again it says its already there...

Another thing, when i try to edit the forumhome template and click save, it just reverts back to the state it was before the edit...

This is really strange...

Any advice please...

Bashy

I don't think your problem is related to this hack, it sounds as if you have a problem in vbulletin.

bashy 12-18-2005 08:41 AM

Strange that...Cause i got loads of mods installed and this is the first time it aint let me change a template....

I will try again when i have rebooted my computer!!!

Bashy

bashy 12-18-2005 08:52 AM

Hi again...

still the same problem, it will not let me edit the forumhome template for love no money, Once i edit it, it just reverts back to as it was before i edited it...
Im gonna go have a word with vB i think and see what they say...
But in the mean time can anyone see anything in the code that could have locked the template?

Code:

stylevar[htmldoctype]
<html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
        <!-- no cache headers -->
        <meta http-equiv="Pragma" content="no-cache" />
        <meta http-equiv="Expires" content="-1" />
        <meta http-equiv="Cache-Control" content="no-cache" />
        <!-- end no cache headers -->
        $headinclude
        <title><phrase 1="$vboptions[bbtitle]">$vbphrase[x_powered_by_vbulletin]</phrase></title>
</head>
<body>
$header
$navbar
<style type="text/css">

#fadeinbox{
position:absolute;
width: 300px;
left: 0;
top: -400px;
padding: 4px;
z-index: 100;
visibility:hidden;
}

</style>

<script type="text/javascript">

//Specify display mode. 3 possible values are:
//1) "always"- This makes the fade-in box load each time the page is displayed
//2) "oncepersession"- This uses cookies to display the fade-in box only once per browser session
//3) integer (ie: 5)- Finally, you can specify an integer to display the box randomly via a frequency of 1/integer...
// For example, 2 would display the box about (1/2) 50% of the time the page loads.

var displaymode="always"

var enablefade="yes" //("yes" to enable fade in effect, "no" to disable)
var autohidebox=["yes", 60] //Automatically hide box after x seconds? [yes/no, if_yes_hide_after_seconds]
var showonscroll="yes" //Should box remain visible even when user scrolls page? ("yes"/"no)
var IEfadelength=1 //fade in duration for IE, in seconds
var Mozfadedegree=0.05 //fade in degree for NS6+ (number between 0 and 1. Recommended max: 0.2)

////////No need to edit beyond here///////////

if (parseInt(displaymode)!=NaN)
var random_num=Math.floor(Math.random()*displaymode)

function displayfadeinbox(){
var ie=document.all && !window.opera
var dom=document.getElementById
iebody=(document.compatMode=="CSS1Compat")? document.documentElement : document.body
objref=(dom)? document.getElementById("fadeinbox") : document.all.fadeinbox
var scroll_top=(ie)? iebody.scrollTop : window.pageYOffset
var docwidth=(ie)? iebody.clientWidth : window.innerWidth
docheight=(ie)? iebody.clientHeight: window.innerHeight
var objwidth=objref.offsetWidth
objheight=objref.offsetHeight
objref.style.left=docwidth/2-objwidth/2+"px"
objref.style.top=scroll_top+docheight/2-objheight/2+"px"

if (showonscroll=="yes")
showonscrollvar=setInterval("staticfadebox()", 50)

if (enablefade=="yes" && objref.filters){
objref.filters[0].duration=IEfadelength
objref.filters[0].Apply()
objref.filters[0].Play()
}
objref.style.visibility="visible"
if (objref.style.MozOpacity){
if (enablefade=="yes")
mozfadevar=setInterval("mozfadefx()", 90)
else{
objref.style.MozOpacity=1
controlledhidebox()
}
}
else
controlledhidebox()
}

function mozfadefx(){
if (parseFloat(objref.style.MozOpacity)<1)
objref.style.MozOpacity=parseFloat(objref.style.MozOpacity)+Mozfadedegree
else{
clearInterval(mozfadevar)
controlledhidebox()
}
}

function staticfadebox(){
var ie=document.all && !window.opera
var scroll_top=(ie)? iebody.scrollTop : window.pageYOffset
objref.style.top=scroll_top+docheight/2-objheight/2+"px"
}

function hidefadebox(){
objref.style.visibility="hidden"
if (typeof showonscrollvar!="undefined")
clearInterval(showonscrollvar)
}

function controlledhidebox(){
if (autohidebox[0]=="yes"){
var delayvar=(enablefade=="yes" && objref.filters)? (autohidebox[1]+objref.filters[0].duration)*1000 : autohidebox[1]*1000
setTimeout("hidefadebox()", delayvar)
}
}

function initfunction(){
setTimeout("displayfadeinbox()", 1)
}

function get_cookie(Name) {
var search = Name + "="
var returnvalue = ""
if (document.cookie.length > 0) {
offset = document.cookie.indexOf(search)
if (offset != -1) {
offset += search.length
end = document.cookie.indexOf(";", offset)
if (end == -1)
end = document.cookie.length;
returnvalue=unescape(document.cookie.substring(offset, end))
}
}
return returnvalue;
}


if (displaymode=="oncepersession" && get_cookie("fadedin")=="" || displaymode=="always" || parseInt(displaymode)!=NaN && random_num==0){
if (window.addEventListener)
window.addEventListener("load", initfunction, false)
else if (window.attachEvent)
window.attachEvent("onload", initfunction)
else if (document.getElementById)
window.onload=initfunction
document.cookie="fadedin=yes"
}


</script>

<!-- main -->
<thread>
        <if condition="$show['guest']">
        <!-- guest welcome message -->       
<DIV id="fadeinbox" style="filter:progid:DXImageTransform.Microsoft.RandomDissolve(duration=1) progid:DXImageTransform.Microsoft.Shadow(color=gray,direction=135) ; -moz-opacity:0">

<table class="tborder" align="center" border="0" cellpadding="6" cellspacing="0" width="600">
<tbody><tr>
        <td class="tcat" align="center">
<phrase 1="$vboptions[bbtitle]">$vbphrase[welcome_to_the_x]</phrase>
        </td>
</tr>
</tbody><tbody id="collapseobj_forumhome_welcomepanel" style="">
<tr>
<td class="alt1" align="center" width="101%">
<phrase 1="faq.php$session[sessionurl_q]" 2="register.php$session[sessionurl_q]">$vbphrase[first_visit_message]</phrase>
<br><br>This box will auto close after 60 seconds.
<br>
</td>
</tr>
</tbody>
</table><br>
<align="center" valign="middle">
</DIV>
        <!-- / guest welcome message -->
        </if>
</thread>
<thread>
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">

</thread>
<thread>
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">

        <tr align="center">
          <td class="thead">&nbsp;</td>
          <td class="thead" width="100%" align="$stylevar[left]">$vbphrase[forum]</td>
          <td class="thead" width="175">$vbphrase[last_post]</td>
          <td class="thead">$vbphrase[threads]</td>
          <td class="thead">$vbphrase[posts]</td>
          <if condition="$vboptions['showmoderatorcolumn']">
          <td class="thead">$vbphrase[moderator]</td>
          </if>
        </tr>
</thead>
$forumbits
<tbody>
        <tr>
                <td class="tfoot" align="center" colspan="<if condition="$vboptions['showmoderatorcolumn']">6<else />5</if>"><div class="smallfont"><strong>
                        <a href="forumdisplay.php?$session[sessionurl]do=markread" rel="nofollow">$vbphrase[mark_forums_read]</a>
                        <if condition="$vboptions['forumleaders']">&nbsp; &nbsp;
                        <a href="showgroups.php$session[sessionurl_q]" rel="nofollow">$vbphrase[view_forum_leaders]</a></if>
                </strong></div></td>
        </tr>
</tbody>
</table>
<!-- /main -->

<br />
<br />

<!-- what's going on box -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<thead>
        <tr>
                <td class="tcat" colspan="2">$vbphrase[whats_going_on]</td>
        </tr>
</thead>
<if condition="$show['loggedinusers']">
<!-- logged-in users -->
<tbody>
        <tr>
                <td class="thead" colspan="2">
                        <a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_activeusers')"><img id="collapseimg_forumhome_activeusers" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_activeusers].gif" alt="" border="0" /></a>
                        <a href="online.php?$session[sessionurl]" rel="nofollow">$vbphrase[currently_active_users]</a>: $totalonline (<phrase 1="$numberregistered" 2="$numberguest" 3="$numberspiders">$vbphrase[x_members_and_y_guests]</phrase>)
                </td>
        </tr>
</tbody>
<tbody id="collapseobj_forumhome_activeusers" style="$vbcollapse[collapseobj_forumhome_activeusers]">
        <tr>
                <td class="alt2"><a href="online.php$session[sessionurl_q]" rel="nofollow"><img src="$stylevar[imgdir_misc]/whos_online.gif" alt="$vbphrase[view_whos_online]" border="0" /></a></td>
                <td class="alt1" width="100%">
                        <div class="smallfont">
                                <div style="white-space: nowrap"><phrase 1="$recordusers" 2="$recorddate" 3="$recordtime">$vbphrase[most_users_ever_online_was_x_y_at_z]</phrase></div>
                                <div>$activeusers</div>
                        </div>
                </td>
        </tr>
</tbody>
<!-- end logged-in users -->
</if>
<tbody>
        <tr>
                <td class="thead" colspan="2">
                        <a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_stats')"><img id="collapseimg_forumhome_stats" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_stats].gif" alt="" border="0" /></a>
                        <phrase 1="$vboptions[bbtitle]">$vbphrase[x_statistics]</phrase>
                </td>
        </tr>
</tbody>
<tbody id="collapseobj_forumhome_stats" style="$vbcollapse[collapseobj_forumhome_stats]">
        <tr>
                <td class="alt2"><img src="$stylevar[imgdir_misc]/stats.gif" alt="<phrase 1="$vboptions[bbtitle]">$vbphrase[x_statistics]</phrase>" border="0" /></td>
                <td class="alt1" width="100%">
                <div class="smallfont">
                        <div>
                                $vbphrase[threads]: $totalthreads,
                                $vbphrase[posts]: $totalposts,
                                $vbphrase[members]: $numbermembers<if condition="$show['activemembers']">,
                                        <span title="<phrase 1="$vboptions[activememberdays]">$vbphrase[within_the_last_x_days]</phrase>">$vbphrase[active_members]: $activemembers</span>
                                </if>
                        </div>
                        <div><phrase 1="member.php?$session[sessionurl]u=$newuserid" 2="$newusername">$vbphrase[welcome_to_our_newest_member_x]</phrase></div>
                </div>
                </td>
        </tr>
</tbody>
<if condition="$show['birthdays']">
<!-- today's birthdays -->
<tbody>
        <tr>
                <td class="thead" colspan="2">
                        <a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_birthdays')"><img id="collapseimg_forumhome_birthdays" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_birthdays].gif" alt="" border="0" /></a>
                        $vbphrase[todays_birthdays]
                </td>
        </tr>
</tbody>
<tbody id="collapseobj_forumhome_birthdays" style="$vbcollapse[collapseobj_forumhome_birthdays]">
        <tr>
                <td class="alt2"><a href="calendar.php?$session[sessionurl]do=getday&amp;day=$today&amp;sb=1"><img src="$stylevar[imgdir_misc]/birthday.gif" alt="$vbphrase[view_birthdays]" border="0" /></a></td>
                <td class="alt1" width="100%"><div class="smallfont">$birthdays</div></td>
        </tr>
</tbody>
<!-- end today's birthdays -->
</if>
<if condition="$show['upcomingevents']">
<tbody>
        <tr>
                <td class="thead" colspan="2">
                        <a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_events')"><img id="collapseimg_forumhome_events" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_events].gif" alt="" border="0" /></a>
                        <if condition="$show['todaysevents']">$vbphrase[todays_events]<else /><phrase 1="$vboptions[showevents]">$vbphrase[upcoming_events_for_the_next_x_days]</phrase></if>
                </td>
        </tr>
</tbody>
<tbody id="collapseobj_forumhome_events" style="$vbcollapse[collapseobj_forumhome_events]">
        <tr>
                <td class="alt2"><a href="calendar.php$session[sessionurl_q]"><img src="$stylevar[imgdir_misc]/calendar.gif" alt="$vbphrase[calendar]" border="0" /></a></td>
                <td class="alt1" width="100%"><div class="smallfont">$upcomingevents</div></td>
        </tr>
</tbody>
</if>
<!-- latest threads -->
<if condition="$show['latestthreads']">
<tbody>
        <tr>
                <td class="thead" colspan="2">
                        <a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_latestthreads')"><img id="collapseimg_forumhome_latestthreads" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_latestthreads].gif" alt="" border="0" /></a>
                        $vbphrase[latest_threads]
                </td>
        </tr>
</tbody>
<tbody id="collapseobj_forumhome_latestthreads" style="$vbcollapse[collapseobj_forumhome_latestthreads]">
        <tr>
                <td class="alt2"><img src="$stylevar[imgdir_statusicon]/forum_new.gif" alt="$vbphrase[latest_threads]" /></td>
                <td class="alt1"><div class="smallfont">$threadbits</div></td>
        </tr>
</tbody>
</if>
<!-- /latest threads -->
</table>
<br />
<!-- end what's going on box -->
<if condition="$show['topXstats']">
        $topXstats
        </if>

<!-- icons and login code -->
<table cellpadding="0" cellspacing="2" border="0" width="100%">
<tr valign="bottom">
        <td>
                <table cellpadding="2" cellspacing="0" border="0">
                <tr>
                        <td><img src="$stylevar[imgdir_statusicon]/forum_new.gif" alt="$vbphrase[contains_new_posts]" border="0" /></td>
                        <td class="smallfont">&nbsp; $vbphrase[forum_contains_new_posts]</td>
                </tr>
                <tr>
                        <td><img src="$stylevar[imgdir_statusicon]/forum_old.gif" alt="$vbphrase[contains_no_new_posts]" border="0" /></td>
                        <td class="smallfont">&nbsp; $vbphrase[forum_contains_no_new_posts]</td>
                </tr>
                <tr>
                        <td><img src="$stylevar[imgdir_statusicon]/forum_old_lock.gif" alt="$vbphrase[a_closed_forum]" border="0" /></td>
                        <td class="smallfont">&nbsp; $vbphrase[forum_is_closed_for_posting]</td>
                </tr>
                </table>
        </td>
        <if condition="!$show['guest']">
                <!-- member logout -->
                <td align="$stylevar[right]"><a href="login.php?$session[sessionurl]do=logout&amp;logouthash=$bbuserinfo[logouthash]"  onclick="return log_out()"><phrase 1="$bbuserinfo[username]">$vbphrase[log_out_x]</phrase></a></td>
                <!-- end member logout -->
        </if>
</tr>
</table>
<!-- / icons and login code -->

$footer
</body>
</html>


harry1951 12-18-2005 11:43 AM

*clicks installed*

Smiry Kin's 12-22-2005 01:39 AM

how do you add -adsense? also how do you make it smaler?

cooltechie 12-29-2005 09:55 PM

Does anyone have this working with CMPS and photopost?

djjeffa 01-02-2006 05:10 PM

i did a boo boo
I didnt read everything you said wich i know i should of.... but anyway
I had this hack when i was running 3.0.8 now i have 3.5.2 and installed it with out removing anything so is there anyway i could remove the old stuff because im seeing double in the acp.

lasor 01-03-2006 12:12 PM

*Installed*

Excellent hack just what I have been looking for.....Thanks

One question. Is it possible with the popup to show this once? When the user has seen this popup and closed the window they do not get the same popup again?

Thanks

rlamego 01-07-2006 03:55 PM

Thanks for the great hack Logician! =)

I have a question though: how can I remove the < br / > that appear before and after the announcement?

I also would like to suggest the compilation of examples to help conditional challenged people like myself =)

Logician 01-07-2006 06:24 PM

Quote:

Originally Posted by rlamego
I have a question though: how can I remove the < br / > that appear before and after the announcement?

If I understood the question correctly, you can remove the <br /> in template "dfh_announcement" Also feel free to remove it at the end of navbar template if you want to remove the preceding new line.

pauloo 01-10-2006 01:28 PM

Futur suggestion: ON/OFF by option in admincp.

bogene2020 01-18-2006 08:45 PM

Quote:

Originally Posted by cooltechie
Does anyone have this working with CMPS and photopost?

I have this working with cmps but I am getting an error when I go to photopost .
The error is below
HTML Code:

Warning: main(./includes/functions_showthread.php): failed to open stream: No such file or directory in /home2/georgiad/public_html/vbgdbase/photos/header-inc.php on line 92
 
Fatal error: main(): Failed opening required './includes/functions_showthread.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home2/georgiad/public_html/vbgdbase/photos/header-inc.php on line 92

I have disabled for now till I can fix the error . Thanks

scootman 01-18-2006 09:47 PM

<font color="Green">Install</font> Great thanks

//Regards

BlackRanger3d 01-20-2006 09:35 PM

I have 3.5.1

I have followed all the instructions but

I don't see it in the VBoption setup section.
And when I look in the plugin manager it is not listed so I can not change any of the hooks.

TIA

bashy 01-20-2006 09:55 PM

Hi

whoopsy...found in the second post, how i missed that i will never know :(

TIA


All times are GMT. The time now is 08:39 PM.

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.01812 seconds
  • Memory Usage 1,970KB
  • 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
  • (3)bbcode_code_printable
  • (1)bbcode_html_printable
  • (4)bbcode_php_printable
  • (18)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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