vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Start New Thread on forumhome (https://vborg.vbsupport.ru/showthread.php?t=303377)

joeychgo 10-14-2013 07:25 AM

Start New Thread on forumhome
 
Im looking for both vb 3 and 4

What im looking for is something that adds a Post New Thread button next to each forum on forumhome, and that clicking it would start a new thread in the associated forum.

I get a lot of questions "How do I start a new thread" from people who don't understand forums.

This forum has something similar (http://www.chimpout.com/forum/forum.php) but its just a tiny icon users will never find.

ozzy47 10-14-2013 08:59 AM

This is for vB4.
You can actually achieve this with a simple template edit (and it's not possible to do automatically without a significant performance detriment). I implemented it using one of the existing statusicons, but you'd obviously be free to change the image (in this particular location, 12x12 is the required dimensions).

In the template forumhome_forumbit_level2_post, find
Code:

        <ul class="forumactionlinks td">
and add below
Code:

            <vb:if condition="$forum['allowposting']"><li class="forumactionlink newthreadlink"><a href="newthread.php?{vb:raw session.sessionurl}do=newthread&amp;forumid={vb:raw forum.forumid}" title="{vb:rawphrase post_new_thread}" style="padding-{vb:stylevar left}:0;"><img src="{vb:stylevar imgdir_statusicon}/thread_new-16.png" height="12" width="12" /></a></li></vb:if>

joeychgo 10-14-2013 09:05 AM

ok, that seems to work. Thank you.. How about vb3?

ozzy47 10-14-2013 09:45 AM

Been awhile since I played on vB3, it s not as flexible as vB4, I can't find the best conditional either, so I used, $show['member']

In the template forumhome_forumbit_level2_post, find
Code:

<if condition="$show['forumsubscription']"><div class="smallfont"><strong><a href="subscription.php?$session[sessionurl]do=removesubscription&amp;f=$forum[forumid]" rel="nofollow">$vbphrase[unsubscribe_from_this_forum]</a></strong></div></if>
and add below
Code:

<if condition="$show['member']"><a href="newthread.php?$session[sessionurl]do=newthread&amp;f=$forum[forumid]" title="Post New Thread" style="padding-left:0;"><img src="$stylevar[imgdir_statusicon]/thread_new.gif" height="12" width="12" /></a></if>


All times are GMT. The time now is 08:58 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.01730 seconds
  • Memory Usage 1,716KB
  • 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
  • (4)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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