vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Design and Graphics Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=253)
-   -   Style Certain Posts - Possible? (https://vborg.vbsupport.ru/showthread.php?t=289381)

aae55555 10-20-2012 07:06 PM

Style Certain Posts - Possible?
 
Hi guys

I would like to make my first posts in a certain forum section appear like this:

http://www.f30post.com/bpnews/style....d.php?t=728763

Any if this is possible? Am i missing something really simple?

I;ve posted a request in the mod request section too.

Thanks!

Screenshot:

https://vborg.vbsupport.ru/external/2012/10/22.jpg

--------------- Added [DATE]1350811069[/DATE] at [TIME]1350811069[/TIME] ---------------

I tried to create a plugin and hook the "template_hook.postbit_messagearea_start" but I can't seem to successfully apply some CSS/style tags to this. I managed to inject some text above the title of the message body however.

Any assistance would be appreciated thx

BirdOPrey5 10-21-2012 10:36 AM

I would go about it like this...

You appear to be using postbit_legacy so go edit the existing postbit_legacy template.

Highlight THE ENTIRE TEMPLATE with your mouse cursor and "COPY" it to the clipboard.

Then add the following-

Code:

<vb:if condition="$post['postcount'] == 1">
<!--- SPECIAL FIRST POST TEMPLAE -->

[ORIGINAL TEMPLATE CODE HERE]

<vb:else />
<!-- Standard postbit-legacy template -->

["Paste" code you copied here]

</vb:if>

So basically your final template will be twice as big as it was. The first half is the special template only for the first post. The second half will be for all other posts.

Now just use HTML to customize the top half into the special first post you want.

Again make sure you are doing this to postbit_legacy since that is the template you currently use.

aae55555 10-21-2012 11:23 AM

Thank you very much BirdOPrey5. I really really appreciate it.

Let me see what I can come up with :) I will update on my progress.

--------------- Added [DATE]1350861304[/DATE] at [TIME]1350861304[/TIME] ---------------

BirdOPrey5 - you are a legend thank you. That worked wonders.


All times are GMT. The time now is 06:59 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.00933 seconds
  • Memory Usage 1,714KB
  • 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
  • (1)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete