![]() |
What style users are using?
I noticed even here it shows on the postbit on the left Style: WHATSTYLEUSERSISUSING . How do i implament this on my board? I have used the search and have only found versions for before 3.5.
|
$style[title]
|
Quote:
|
Quote:
|
I'm currently using this one -
https://vborg.vbsupport.ru/showthread.php?t=92009 It does add a query to showthread but I've never had much of a problem with that. It does not currently work in PMs though. |
Quote:
|
You could do something like this:
Hook: postbit_display_complete PHP Code:
Code:
Style: $stylename PHP Code:
The above should work ;) Chris |
Wouldn't that be a slow code if you had like a dozen styles? (as I do hehee)
Maybe modifying the $post query through hooks to add left join commands might be best. /me starts to ponder. |
It wouldn't necessarily be slow - It would be tedious for many styles but it doesn't add any queries ;)
Chris |
Heres the code i added to the hook and they ended up just showing that everyone uses the last style on this list. What did i do wrong?
if ($this->post->userinfo['styleid']=='16') { $stylename = 'Rap Basement v1'; } elseif ($this->post->userinfo['styleid']=='14') { $stylename = 'D12 World'; } elseif ($this->post->userinfo['styleid']=='13') { $stylename = 'Basic 2004'; } elseif ($this->post->userinfo['styleid']=='11') { $stylename = 'Green 2003'; } elseif ($this->post->userinfo['styleid']=='12') { $stylename = 'Blue 2002'; } else { $stylename = 'Low Budget'; } |
Anyone? I dont understand how its hard to get an answer on how to display styles easily.
Its on this board so i figure someone would have a working way. ? |
<a href="https://vborg.vbsupport.ru/showthread.php?t=92009" target="_blank">https://vborg.vbsupport.ru/showthread.php?t=92009</a>
I posted a snippet of code to avoid the query. |
Quote:
|
Quote:
|
Quote:
PHP Code:
HTML Code:
Style Used: $post[styletitle] To make sure you don't display styles that the user cannot select (due to style changing not allowed, style not selectable, user ues not have permission to use style) you would need more complex conditions. |
Tryed it and nothing showed up in the postbit it simply displayed the following:
Style: (nothing was here) Just to confirm the postbit_display_complete i would add something there by simply going to add new plugin and supplying the code in the bottom after i select postbit_disp_complete right? |
will that show even if someone chooses the style in the quick style chooser?
|
All times are GMT. The time now is 05:02 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 | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|