Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 04-22-2014, 05:37 AM
Set3sh's Avatar
Set3sh Set3sh is offline
 
Join Date: Jan 2013
Location: Romania
Posts: 35
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Subforum Icons

Hello,

I'd like to remove all subforum status icons and replace it with
&bull; <a href="{vb:link forum, {vb:raw row}}">{vb:raw row.title}</a> if there are not new posts
and with
<b>&rarr; <a href="{vb:link forum, {vb:raw row}}">{vb:raw row.title}</a></b> if there are new posts.

Any hints regarding how can I do this?

Thank you.
Reply With Quote
  #2  
Old 04-25-2014, 03:49 PM
Set3sh's Avatar
Set3sh Set3sh is offline
 
Join Date: Jan 2013
Location: Romania
Posts: 35
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

So, not even a single idea?
Reply With Quote
  #3  
Old 04-25-2014, 04:08 PM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well, I can tell you that you'll need to modify the forumhome_subforums template and that the variable you will want to look at is $row['statusicon'] to determine if it is going to be bold or not. So, play around with that and post your exact template change if you need more help.
Reply With Quote
  #4  
Old 04-25-2014, 04:13 PM
Set3sh's Avatar
Set3sh Set3sh is offline
 
Join Date: Jan 2013
Location: Romania
Posts: 35
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is my forumhome_subforums template:

<style>
.subforums ol.subforumlist { float: left; width: 100%; margin: 0; padding: 0; }
.subforumlist li.subforum { float: left; width: 33%; margin: 0; padding: 0; clear:none;}
</style>

<div class="subforums">
<br />
<h4 class="subforumlistlabel">{vb:rawphrase subforums}:</h4>
<ol class="subforumlist commalist">
<vb:each from="subforums" value="row">
<li class="subforum">
<vb:if condition="$row['canpost']">
<vb:if condition!="CONDITION-TO-CHECK-NEW-POSTS?"> &bull; <a href="{vb:link forum, {vb:raw row}}">{vb:raw row.title}</a></vb:if>
<vb:else />
<b>&rarr; <a href="{vb:link forum, {vb:raw row}}">{vb:raw row.title}</a></b>
</vb:if>
</li>
</vb:each>
</ol>
</div>

I need the condition...
Reply With Quote
  #5  
Old 04-30-2014, 03:30 PM
Set3sh's Avatar
Set3sh Set3sh is offline
 
Join Date: Jan 2013
Location: Romania
Posts: 35
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Any hints regarding how can I check if a subforum has new posts?
Reply With Quote
  #6  
Old 04-30-2014, 04:03 PM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I already told you to look at the value of $row['statusicon'] for the forum. Print it out in the template and you will see what I mean.

{vb:raw row.statusicon}
Reply With Quote
  #7  
Old 05-01-2014, 02:32 PM
Set3sh's Avatar
Set3sh Set3sh is offline
 
Join Date: Jan 2013
Location: Romania
Posts: 35
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Where should I look for it and how should I use it?
I don't want to use the default forum status icons for subforums, I'd like to display a dot and a bold name of the subforum if it has new posts..
Sorry for being a pain lol..
Reply With Quote
  #8  
Old 05-01-2014, 04:44 PM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Like...
<vb:if condition!="$row['statusicon'] == 'something_here'">

but, in order to find the 'something_here', you need to print it out and see what the value is first. So, add this line to your template and see what value gets spit out for when there are new posts and when there are not so that you know how to finish that condition.
{vb:raw row.statusicon}
Reply With Quote
  #9  
Old 05-02-2014, 06:02 AM
Set3sh's Avatar
Set3sh Set3sh is offline
 
Join Date: Jan 2013
Location: Romania
Posts: 35
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Where's the thanks button Lynne?
Thank you
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:08 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.05337 seconds
  • Memory Usage 2,235KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (9)postbit
  • (9)postbit_onlinestatus
  • (9)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete