How to add forum names into Today's Posts / New Topics

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Mark.B
    vBulletin Support
    • Feb 2004
    • 24286
    • 6.0.X

    How to add forum names into Today's Posts / New Topics

    One major thing that has been missing in vB5, has been the name of the forum in the Today's Posts / New Posts results. You are told the name of the topic, who started it, when it was started, who made the most recent post, etc...but you are not told what forum it's in.

    For many, this is essential, as they only want to read threads in forums they are interested in.

    Well, here's how to add this back in.

    First, add this to the template css_additional.css
    Code:
    /* Today's Posts - Forum Title */
    .f-title
    {
    font-weight: normal;
    }
    
    .topic-list-container .topic-list .topic-item .cell-topic .topic-info
    {
    font-size: 12px;
    }
    
    .topic-list-container .topic-list .topic-item td
    {
    vertical-align: middle;
    }
    /* Today's Posts - Forum Title */
    Next, edit the template display_Topics_item

    Find BOTH instances of this:
    Code:
    {vb:if "!empty($topic['userid'])", {vb:rawphrase started_by_link_x_y, {vb:var profileUrl}, {vb:raw topic.authorname}},{vb:rawphrase started_by_x, {vb:raw guestname}}}{vb:if "isset($topic['created'])", {vb:rawphrase on_date_x, {vb:datetime {vb:raw topic.created}}}}
    Add IMMEDIATELY afterwards: (Don't leave a space! And take care not to erase any of the curly brackets!)
    Code:
    <span class="f-title"> in <a href="{vb:url {vb:raw topic.channelroute}, {vb:raw topic}}">{vb:raw topic.channeltitle}</a></span>
    Last edited by Mark.B; Wed 22 Mar '17, 3:32pm.
    MARK.B
    vBulletin Support
    ------------
    My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
    My Unofficial vBulletin Cloud Demo: https://www.adminammo.com
  • Merenguista
    Senior Member
    • Jul 2010
    • 555
    • 5.3.x

    #2
    Good job Mark .. Thanks ..

    Comment

    • anwar513
      Senior Member
      • Sep 2010
      • 277
      • 5.2.x

      #3
      Thank you for the tutorial.....

      Comment

      • John8
        Member
        • Jan 2014
        • 32
        • 5.0.X

        #4
        Very nice thank you

        Comment

        • Guest

          #5
          Good job!

          Comment

          • IggyP
            Senior Member
            • Mar 2012
            • 680

            #6
            nice to see this it will be in 5.1.0?

            Comment

            • Mark.B
              vBulletin Support
              • Feb 2004
              • 24286
              • 6.0.X

              #7
              Originally posted by IggyP
              nice to see this it will be in 5.1.0?
              No it's not in 5.1.0. It's just a workaround.
              MARK.B
              vBulletin Support
              ------------
              My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
              My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

              Comment

              • Guest

                #8
                What if I would like them to appear in a widget like 'Last Posts' too? The $page condition won't work. Is there another condition I can use?

                Comment

                • Mark.B
                  vBulletin Support
                  • Feb 2004
                  • 24286
                  • 6.0.X

                  #9
                  Originally posted by GuiltyNL
                  What if I would like them to appear in a widget like 'Last Posts' too? The $page condition won't work. Is there another condition I can use?
                  Do you mean like I have done here?

                  (That page is just a very large Last Posts search widget)
                  MARK.B
                  vBulletin Support
                  ------------
                  My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
                  My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

                  Comment

                  • Guest

                    #10
                    Yes. But we have a widget on our homepage that show some last posts.

                    Comment

                    • Mark.B
                      vBulletin Support
                      • Feb 2004
                      • 24286
                      • 6.0.X

                      #11
                      It can be done, it shows in the widgets ok. I can try and write something up if you like, it's a similar process to the above.
                      MARK.B
                      vBulletin Support
                      ------------
                      My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
                      My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

                      Comment

                      • Guest

                        #12
                        I've solved it I think, i changed the condition:

                        condition="$page['title'] == 'Search Result' || condition="$page['title'] == 'Home Page Name'

                        It seems to work! But it would be nice if I can assign the condition to the name of the widget. Is that possible?

                        Like:

                        condition="$widget['title'] == 'Last Posts'

                        Comment


                        • IggyP
                          IggyP commented
                          Editing a comment
                          could you please share the exact new coding? im not sure how much of the old line to leave in

                        • Guest
                          Guest commented
                          Editing a comment
                          Sorry, doesn't work as comment.
                      • Mark.B
                        vBulletin Support
                        • Feb 2004
                        • 24286
                        • 6.0.X

                        #13
                        Doesn't look like the title of the module is available in the relevant template (display_contenttype_searchwidget_item_header).
                        MARK.B
                        vBulletin Support
                        ------------
                        My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
                        My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

                        Comment

                        • IggyP
                          Senior Member
                          • Mar 2012
                          • 680

                          #14
                          im curious about the widgets listing....

                          also, i was wondering if this link would look better displayed where it is now (in the topics column) or in the "last posts" column as there is generally less text there.....ive basically gotten used to it, however in my "latest topics" widget i think it clearly would look best in the last post column so im wondering how i can do this?? (both listing in latest topics widget and in last post column)

                          thanks

                          Comment


                          • IggyP
                            IggyP commented
                            Editing a comment
                            hmm, some issues making that post but then i noticed this is 5.1.0 rc1....
                        • Mark.B
                          vBulletin Support
                          • Feb 2004
                          • 24286
                          • 6.0.X

                          #15
                          Originally posted by IggyP
                          im curious about the widgets listing....

                          also, i was wondering if this link would look better displayed where it is now (in the topics column) or in the "last posts" column as there is generally less text there.....ive basically gotten used to it, however in my "latest topics" widget i think it clearly would look best in the last post column so im wondering how i can do this?? (both listing in latest topics widget and in last post column)

                          thanks
                          It could easily go there....just play with the template.
                          MARK.B
                          vBulletin Support
                          ------------
                          My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
                          My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

                          Comment

                          Related Topics

                          Collapse

                          Working...