Announcement

Collapse
No announcement yet.

VB 4.2 Post thread post reply button

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • [Forum] VB 4.2 Post thread post reply button

    I have installed Vb 4.2 and vbseo. I want to enable post thread button inside the sub-forum for un-registered member. If the member click that button they needs to direct login page. Similarly i need this for post reply also

  • #2
    Needs a template edit; Please be aware with editing templates that you will need to reapply these changes if you upgrade.

    In template FORUMDISPLAY:

    First take a copy of what's already there, in case you already have any customisations and need to restore it.
    Then;

    Find this code:
    Code:
    <vb:if condition="$show['newthreadlink']"><a href="{vb:raw $vboptions.vbforum_url}{vb:if "$vboptions['vbforum_url']", '/', ''}newthread.php?{vb:raw session.sessionurl}do=newthread&amp;f={vb:raw foruminfo.forumid}" rel="nofollow" class="newcontent_textcontrol" id="newthreadlink_top"><span>+</span> {vb:rawphrase post_new_thread}</a></vb:if>
    Replace with this:
    Code:
    <a href="{vb:raw $vboptions.vbforum_url}{vb:if "$vboptions['vbforum_url']", '/', ''}<vb:if condition="$show['guest']">register.php?{vb:raw session.sessionurl}<vb:else />newthread.php?{vb:raw session.sessionurl}do=newthread&amp;f={vb:raw foruminfo.forumid}</vb:if>" rel="nofollow" class="newcontent_textcontrol" id="newthreadlink_top"><span>+</span> {vb:rawphrase post_new_thread}</a>
    Then find this code:
    Code:
    	<vb:if condition="$show['newthreadlink']">
    		<a href="{vb:raw $vboptions.vbforum_url}{vb:if "$vboptions['vbforum_url']", '/', ''}<vb:if condition="$show['guest']">register.php?{vb:raw session.sessionurl}<vb:else />newthread.php?{vb:raw session.sessionurl}do=newthread&amp;f={vb:raw foruminfo.forumid}</vb:if>" rel="nofollow" class="newcontent_textcontrol" id="newthreadlink_bottom"><span>+</span> {vb:rawphrase post_new_thread}</a>
    	</vb:if>
    Replace with this:
    Code:
    		<a href="{vb:raw $vboptions.vbforum_url}{vb:if "$vboptions['vbforum_url']", '/', ''}<vb:if condition="$show['guest']">register.php?{vb:raw session.sessionurl}<vb:else />newthread.php?{vb:raw session.sessionurl}do=newthread&amp;f={vb:raw foruminfo.forumid}</vb:if>" rel="nofollow" class="newcontent_textcontrol" id="newthreadlink_bottom"><span>+</span> {vb:rawphrase post_new_thread}</a>
    That will make the New Thread button appear to guests, but if they click it, it will take them the registration page.
    Members will get the new thread screen as normal.
    MARK.B | vBULLETIN SUPPORT

    TalkNewsUK - My vBulletin 5.6.4 Demo
    AdminAmmo - My Cloud Demo

    Comment


    • #3
      Thanks for this update. I have updated above code and it is working. But I couldn't find the below code in the forumdisplay template.

      Comment


      • #4
        Might be the spacing that causes that.

        Try searching for this:
        Code:
        {vb:rawphrase post_new_thread}
        The second instance of that should highlight the block of code to look for.
        MARK.B | vBULLETIN SUPPORT

        TalkNewsUK - My vBulletin 5.6.4 Demo
        AdminAmmo - My Cloud Demo

        Comment

        Related Topics

        Collapse

        Working...
        X