vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   $forumid variable in $Globals for postbit,forumdisplay,forumhome,headerinclude,navba r (https://vborg.vbsupport.ru/showthread.php?t=294853)

kh99 02-07-2013 03:02 PM

Quote:

Originally Posted by cellow (Post 2402629)
is there any other location where i can hook your plugin?

I suppose it could be the template modification system. Try using hook global_start instead.


Quote:

Originally Posted by Simon Lloyd (Post 2402644)
I've created this https://vborg.vbsupport.ru/showthread.php?t=286403 which may help, really simple and does the job (pretty much) :)

That's pretty good, but I couldn't see where it lets you do it by forumid.

Simon Lloyd 02-07-2013 03:11 PM

Lol, i hadn't built that in (but i could do) as the person that comissioned it didnt need that, but it has the ability to put seperate variables in different forums, the ads dont show if you dont add the variable.

I suppose i could extend it to add the variable depending on forum selection, may be a little while as i dont have a lot of time at the moment.

kh99 02-07-2013 03:18 PM

Oh, I see - that could be used by making one of the variables a list of forums, then using that in a conditional, so it would allow you to edit the list in the settings instead of having to go to a plugin. Yeah, seems like that would work.

Simon Lloyd 02-07-2013 04:15 PM

Quote:

Originally Posted by kh99 (Post 2402665)
Oh, I see - that could be used by making one of the variables a list of forums, then using that in a conditional, so it would allow you to edit the list in the settings instead of having to go to a plugin. Yeah, seems like that would work.

Lol, now thats thinking out of the box! :) i wouldn't have thought of it as easy as that!

cellow 02-07-2013 06:32 PM

so how can i solve my problem with Simon Lloyd mod ??? i didnt really get what u guys talking about...

@kh99
even global_start hook didnt work :(

kh99 02-07-2013 07:27 PM

Well, you'd have to convert a string of number to an array then use it in an in_array(). But reading what you psted above, it wasn't working using the in_array() condition so there's got to be some other problem with your condition. If you use the plugin code and this condition do you see ads?

Code:

<if condition="(($post[postcount] % $vboptions[maxposts] == 1)) AND ($show['member']) AND 1">

cellow 02-07-2013 07:41 PM

hmmm, very weird...

i tried:

<if condition="(($post[postcount] % $vboptions[maxposts] == 1))
ads here
</if>

even then, i dont see ads inside the postbit

it still saves somewhere my old conditions, because for "guests" the ads are shown, but not for members...

kh99 02-07-2013 07:51 PM

Maybe that's just a typo, but try this:

Code:

<if condition="($post[postcount] % $vboptions[maxposts]) == 1">
ads here
</if>


Also, make sure the template you're editing is in the same style you're using.

cellow 02-07-2013 07:59 PM

doesnt work ... i dont understand why?!?

i delete datastore cache, deactivated, flushed xcache, rebuild bit_fields .... everything tried... i dont understand, why my this condition doesnt work in postbit_legacy template:

Code:

               
<!-- message -->
<if condition="($post[postcount] % $vboptions[maxposts]) == 1">
<div style="float:left; width:301px; height:251px; border:0px solid #336699;margin-left:2px;margin-right:15px;">

adtag comes here ...
</div>
</if>
                <div id="post_message_$post[postid]">
                        $ad_location[ad_showthread_firstpost_start]
                        $post[message]
                </div>
                <!-- / message -->


kh99 02-07-2013 08:09 PM

Are you sure you're using postbit_legacy and not postbit (is the user information on the left or on top)? And if you have more than one style are you editing the same one that you're using?


All times are GMT. The time now is 06:37 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.02441 seconds
  • Memory Usage 1,738KB
  • 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
  • (3)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
  • (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