Announcement

Collapse
No announcement yet.

Where to change post background?

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

  • Where to change post background?

    Can't find it out. Please help to change 2 background colors indicated on a picture. Also please advice where to increase font size of yexy in post body.
    Thanks in advance.
    Oregon Fishing Forum

  • #2
    You can use:-
    Code:
    .b-post--first .b-post__body {
    background: green;}
    Changing green to whatever colour you want - for the first post in the thread.

    You can use:-

    Code:
    .b-post__body {
      background: blue;}
    To change the reply colour to blue or whatever other colour you like, but as yet I haven't found a way to make it alternate colours. I'll admit I haven't looked too deeply into it, to be sure. But, if nothing else, that'll give you a starting point.

    Obnoxious colours, I know, but it's just to show you lol

    Click image for larger version

Name:	colours.png
Views:	20
Size:	35.9 KB
ID:	4346131
    I know violence isn't the answer . . . I got it wrong on purpose
    Rep Owners - New forum for reptile owners/lovers
    sigpic

    Comment


    • #3
      Thanks for reply.


      Code:
      .b-post__body {
      background: blue;}
      nope, doesn't work (
      Oregon Fishing Forum

      Comment


      • #4
        Where did you put it? It needs to be in the css_additional.css template for the style you are using.

        Click image for larger version

Name:	cssadditiona.png
Views:	14
Size:	16.8 KB
ID:	4346137
        I know violence isn't the answer . . . I got it wrong on purpose
        Rep Owners - New forum for reptile owners/lovers
        sigpic

        Comment


        • #5
          There are style variables for the post backgrounds.

          The left column with the user information is post_background

          The background for the starter post are thread_starter_background and thread_reply_background, respectively.

          You can even change the backgrounds for deleted and unapproved posts. All of these are in the PostRepliesAndComments stylevar group.
          Translations provided by Google.

          Wayne Luke
          The Rabid Badger - a vBulletin Cloud customization and demonstration site.
          vBulletin 5 Documentation - Updated every Friday. Report issues here.
          vBulletin 5 API - Full / Mobile
          I am not currently available for vB Messenger Chats.

          Comment


          • #6
            The rule of thumb for style customizations is to do it first via style variables. If a style variable does not exist for an element on a page, then do it via css_additional.css template. You would want to minimize custom styles in css_additional template as much as possible when you can do it via style variables. Otherwise, you would accumulate tons of custom CSS rules over time and that would be hard to maintain.

            GIPHY for vB5 AutoLinker Social Icons in Postbit Audio Player Clear Cache Cron DragDrop Upload Topic AutoUpdate Force Read Stop Links in Posts ...and more!

            Comment


            • #7
              Originally posted by Wayne Luke View Post
              There are style variables for the post backgrounds.

              The left column with the user information is post_background

              The background for the starter post are thread_starter_background and thread_reply_background, respectively.

              You can even change the backgrounds for deleted and unapproved posts. All of these are in the PostRepliesAndComments stylevar group.
              Thank you, Wayne Luke. It works!
              Please advise how to change font size for forum titles, subforum titles, and links and description in module blocks.
              Thanks in advance.
              Oregon Fishing Forum

              Comment


              • #8
                This is the process I take to know how to style an element using stylevars or css_additional template.

                http://www.vbulletin.com/forum/forum...30#post4182030

                GIPHY for vB5 AutoLinker Social Icons in Postbit Audio Player Clear Cache Cron DragDrop Upload Topic AutoUpdate Force Read Stop Links in Posts ...and more!

                Comment


                • AnatoliyOFF
                  AnatoliyOFF commented
                  Editing a comment
                  I'm sorry, but it sounds too complicated for me... Can you advice like Wayne Luke did?

              • #9
                Glenn, for example I follow your instruction for a link (topic title) in a module box (number 3 on a picture above).

                I found that the link in a div class=b-post-sm__title ellipsis. Search in tamplate giver me 2 results:
                display_contenttype_searchwidget_Channel
                display_contenttype_searchwidget_item_header

                in display_contenttype_searchwidget_Channel
                <div class="b-post-sm__title ellipsis">
                <a href="{vb:raw url}">
                {vb:raw title}
                </a>
                </div>

                display_contenttype_searchwidget_item_header
                <div class="b-post-sm__title ellipsis">
                {vb:set qs.p, {vb:raw conversation.nodeid}}
                <vb:if condition="$postType == 'reply' OR $postType == 'comment'">
                {vb:set url, {vb:url {vb:raw conversation.starterroute}, {vb:raw conversation}, {vb:raw qs}}}
                {vb:strcat url, "#post"}
                {vb:strcat url, {vb:raw conversation.nodeid}}
                <vb:if condition="$postType == 'reply'">
                {vb:rawphrase search_module_topic_link_reply_to_x, {vb:var url}, {vb:raw conversation.startertitle}}
                <vb:else />
                {vb:rawphrase search_module_topic_link_comment_on_x, {vb:var url}, {vb:raw conversation.startertitle}}
                </vb:if>
                <vb:else />
                <a href="{vb:url {vb:raw conversation.starterroute}, {vb:raw conversation}}">{vb:raw conversation.startertitle}</a>
                </vb:if>
                </div>

                there is no conversation.startertitle Style Variable Editor. The end.
                Oregon Fishing Forum

                Comment


                • #10
                  Search for each class by itself... You're looking for "b-post-sm__title". Should return results in CSS templates.
                  Translations provided by Google.

                  Wayne Luke
                  The Rabid Badger - a vBulletin Cloud customization and demonstration site.
                  vBulletin 5 Documentation - Updated every Friday. Report issues here.
                  vBulletin 5 API - Full / Mobile
                  I am not currently available for vB Messenger Chats.

                  Comment


                  • AnatoliyOFF
                    AnatoliyOFF commented
                    Editing a comment
                    Guys, you are torturing me. ) I'm bad in english, I'm bad in css...
                    I put in custom this:
                    .b-post-sm__title {
                    font-size: 16px;
                    }
                    it didn't change the size of topic titles in module box...

                • #11
                  You may want to learn basic HTML and CSS first.

                  https://www.google.com/search?q=html...eginners&rct=j


                  GIPHY for vB5 AutoLinker Social Icons in Postbit Audio Player Clear Cache Cron DragDrop Upload Topic AutoUpdate Force Read Stop Links in Posts ...and more!

                  Comment


                  • #12
                    Originally posted by Glenn Vergara View Post
                    You may want to learn basic HTML and CSS first.

                    https://www.google.com/search?q=html...eginners&rct=j
                    No I don't. ) I'm 50 years old, I'm not planning to do html & css. I didn't touch my VB4 for years, but I had to move to VB5.
                    P.S. Is it my fault that VB out of box uses unreadably small fonts? Why not to put by defaul those sizes that you use on your own forum?
                    Oregon Fishing Forum

                    Comment


                    • #13
                      I guess I should better go to a ticket system to get help...
                      Oregon Fishing Forum

                      Comment


                      • #14
                        Change the body_font style variable to something between 12 and 16 pt (not px). Adjust as necessary. It will change all the fonts to be larger.

                        Any _font style variable will do just that. Change the font. Style Variables are organized in groups depending on what they affect. Modules are in the Modules groups for example.
                        Translations provided by Google.

                        Wayne Luke
                        The Rabid Badger - a vBulletin Cloud customization and demonstration site.
                        vBulletin 5 Documentation - Updated every Friday. Report issues here.
                        vBulletin 5 API - Full / Mobile
                        I am not currently available for vB Messenger Chats.

                        Comment


                        • #15
                          Originally posted by Wayne Luke View Post
                          Change the body_font style variable to something between 12 and 16 pt (not px). Adjust as necessary. It will change all the fonts to be larger.

                          Any _font style variable will do just that. Change the font. Style Variables are organized in groups depending on what they affect. Modules are in the Modules groups for example.
                          Thank you!
                          Oregon Fishing Forum

                          Comment

                          Related Topics

                          Collapse

                          Working...
                          X