vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=236)
-   -   Miscellaneous Hacks - DJ's Dynamic Tab Content for Postbit_Legacy (https://vborg.vbsupport.ru/showthread.php?t=184136)

jeefo 12-21-2008 09:04 PM

what agreat modification ,,
thank you my dear ,, Installed

just add
Code:

direction:rtl;
in css file .. arabic forums :)

and it works fine..

Digital Jedi 12-21-2008 10:58 PM

Quote:

Originally Posted by jeefo (Post 1690612)
what agreat modification ,,
thank you my dear ,, Installed

just add
Code:

direction:rtl;
in css file .. arabic forums :)

and it works fine..

Good to know. I'll have to add that in the second post.

stickskills 01-07-2009 02:23 AM

I feel like a goofball for posting this, but I'm not familiar with all of the variables.. if anyone could help, I could appreciate it.

I'm trying to post certain usergroups, basically staff, in this postbit_legacy. Could anyone help me set up an if condition (I guess that's what it would be), to do so? What I mean is, if a user is a moderator, admin, or part of a special group, their group displays in their postbit_legacy along with the other information I already have in there. Thanks!

Digital Jedi 01-07-2009 04:11 AM

Quote:

Originally Posted by stickskills (Post 1703811)
I feel like a goofball for posting this, but I'm not familiar with all of the variables.. if anyone could help, I could appreciate it.

I'm trying to post certain usergroups, basically staff, in this postbit_legacy. Could anyone help me set up an if condition (I guess that's what it would be), to do so? What I mean is, if a user is a moderator, admin, or part of a special group, their group displays in their postbit_legacy along with the other information I already have in there. Thanks!

If you haven't already, assign your Usergroups ranks in the User Rank Manager in the Admin CP. Then you'd look for this line of code and move it to where you ever want it to appear in the tabs. By default, it shows just below the avatar.

Code:

<if condition="$post['rank']"><div class="smallfont">$post[rank]</div></if>

Head Roller 01-07-2009 01:25 PM

Hello.... First of all.. thanks for the fantastic mod. If I get it all sorted out it is going to be a HUGE help to me and my members.

I am not a coder, I am 100% hack... I try to add to my coding knowledge as I run into issues hacking..... I need a little bit of general information that should allow me to get this sorted out... if anyone is willing...

I have NUMEROUS additions and modifications to my board, so my postbit is huge, which is why I need this hack. The issue I am having, however, is that a large number of the mods use the template hook[postbit_userinfo_right_after_posts], so even if I move the entire hook to a tab, it is too much. That is not what I want to do though. I want to figure out where the code is in each mod that is picked up by the hook so that I can "release" it from the hook and manually configure it into my postbit. Of course, I am only assuming that this is even possible.

Is there any article already written, source or easy response to help me? I am willing to buy a book, research, read or whatever it takes... I just need pointed in the right direction.

Thanks to anyone who can point the general direction to the needle in my haystack.
:)

Digital Jedi 01-07-2009 03:42 PM

Quote:

Originally Posted by Head Roller (Post 1704178)
Hello.... First of all.. thanks for the fantastic mod. If I get it all sorted out it is going to be a HUGE help to me and my members.

I am not a coder, I am 100% hack... I try to add to my coding knowledge as I run into issues hacking..... I need a little bit of general information that should allow me to get this sorted out... if anyone is willing...

I have NUMEROUS additions and modifications to my board, so my postbit is huge, which is why I need this hack. The issue I am having, however, is that a large number of the mods use the template hook[postbit_userinfo_right_after_posts], so even if I move the entire hook to a tab, it is too much. That is not what I want to do though. I want to figure out where the code is in each mod that is picked up by the hook so that I can "release" it from the hook and manually configure it into my postbit. Of course, I am only assuming that this is even possible.

Is there any article already written, source or easy response to help me? I am willing to buy a book, research, read or whatever it takes... I just need pointed in the right direction.

Thanks to anyone who can point the general direction to the needle in my haystack.
:)

What you can try to do is check each of your modifications plugins that use the postbit's template hook. The easiest way to do this is to go through your Plugin Manager and peruse each of your product's plugins. Look for the plugins that use the postbit_display_complete hook. Disable them one at a time, each time checking to see if something disappears from your forum's postbits. You've likely found the right plugin.

Now the next part is trickier. In some cases, the plugin calls a template to display it's information. So in those cases, you can turn the plugin off and look for the template it calls and copy and paste that template information into your postbit_legacy template instead. For instance, DownloadsII postbit information is controlled via the downloads_postbit_display_complete plugin. And all that plugin says is:

PHP Code:

global $vbulletin;
if (
$vbulletin->options['ecshowmemberinfo'])
{
 eval(
'$template_hook[postbit_userinfo_right_after_posts] .= " ' fetch_template('downloads_memberinfo_postbit') . '";');


Notice the fetch_template part calls a template called downloads_memberinfo_postbit. That's the template you can go into and copy and paste what's in there into your postbit_legacy, in turn turning this plugin off.

In other cases, the plugin might reference a PHP file, in which case you'd have to go to that file and search for the code to duplicate. Another case might have the postibit code worked right into the plugin itself. In all cases though, provided you can find the HTML code used, you can just disable that one plugin and post the HTML code wherever you want (and however you want it to look) in your postbit_legacy template, removing any extraneous code inherent to PHP, like escaped quotations \"

Head Roller 01-07-2009 04:03 PM

Wow.. thank you so much... that actually makes sense to me. Now I just have to find a quiet place and a few hours to make it happen.. hehe..

THANK YOU!!

Digital Jedi 01-07-2009 06:31 PM

No problem. And I meant to say escaped quotations towards the end there. \"

Head Roller 01-08-2009 01:36 AM

I DID IT!! I was able to release everything from the hooks and now I am just struggling with what to put in each tab. Thank you so much for your help. I ran into at least one of EACH example you provided, plus and additional scenario. When I get my post bit all perfect, I will post the codes for some additional hacks.

:)

Digital Jedi 01-08-2009 02:16 AM

I should probably put together an FAQ like I did for my AME XML threads. Be right back.


All times are GMT. The time now is 02:56 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.01358 seconds
  • Memory Usage 1,758KB
  • 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_php_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)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