Announcement

Collapse
No announcement yet.

social icons

Collapse
X
Collapse
First Prev Next Last
 
  • Filter
  • Time
  • Show
Clear All
new posts

    social icons

    So what is the trick or code to get the Social Media Icons to the left of your search box??

    #2
    That's a template hook type of mod. I have not posted it yet but it would be in vBulletin 5 Products and Extensions channel and not here in this Core Hacks channel which is mainly for PHP hacks.
    Helpful? Donate. Thanks!
    Buy me a coffeePayPal QR Code
    Fast VPS Host for vBulletin:
    A2 Hosting & IONOS

    Comment


      #3
      There is a product called Social Buttons, but it broke at vB5.0 and has never been updated.
      I tore it apart and extracted the PHP code that made it work, injected it into a PHP Module and added it to my site.
      Click image for larger version

Name:	Clipboard01.jpg
Views:	407
Size:	10.1 KB
ID:	1272
      But that is not a smooth or simple approach. Works for me mind you, but would be a mess for most.
      Maybe I will see if I can make a simpler hack, but I suspect Glenn can do one easier on the community

      Comment


        #4
        What about getting them as seen here?

        Comment


          #5
          That's using the AddThis service which I'm using it here too. I configured the social share buttons to appear on the left for desktop and at the bottom for mobile.
          Helpful? Donate. Thanks!
          Buy me a coffeePayPal QR Code
          Fast VPS Host for vBulletin:
          A2 Hosting & IONOS

          Comment


          • William
            William commented
            Editing a comment
            Thanks Glenn on the async. Yes I meant the Related Posts Addthis app. I added the app to the addthis dashboard and went through the settings. No other code should need be added but it doesn't show up. I was just curious about whether you played around with it for this site.

          • glennrocksvb
            glennrocksvb commented
            Editing a comment
            I think the Related Posts only shows up after sharing. Take a look at the Advanced Options for the Sidebar. Hover over the "?" icon for the "Related Posts Message" option.

          • glennrocksvb
            glennrocksvb commented
            Editing a comment
            William, thanks for the coffee!

          • William
            William commented
            Editing a comment
            Enjoy Glenn And I contacted Addthis support, they said once the related posts is installed it can take 24-48 hours for them to crawl the site in order to recommend posts. That really answered my curiosity because I was unclear as to how this little app could work. I have set it up in my dashboard and will look forward to when it appears. G'night bro - William

          • glennrocksvb
            glennrocksvb commented
            Editing a comment
            That makes sense. I will try to use it too.

          #6
          Originally posted by NumNum View Post
          Where did you add the code? In an html module?
          It depends on what type of share tool you chose. In my case I chose "Sidebar" and I added the code at the bottom using a template hook. It could also be added in head_include template. It is recommended to add "async" attribute to the <script> tag to prevent it from affecting page load performance.

          Code:
          <script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=xxxxxxx" [color=red]async[/color]></script>
          Helpful? Donate. Thanks!
          Buy me a coffeePayPal QR Code
          Fast VPS Host for vBulletin:
          A2 Hosting & IONOS

          Comment


          • NumNum
            NumNum commented
            Editing a comment
            What hook location did you use?

          • glennrocksvb
            glennrocksvb commented
            Editing a comment
            footer_before_body_end

          • NumNum
            NumNum commented
            Editing a comment
            What is the name of the template this hook will trigger?

          • glennrocksvb
            glennrocksvb commented
            Editing a comment
            You can name the template you will create whatever you want.

          #7
          I want to add it just below page title, just like wayne has done. I picked the html one.

          Comment


            #8
            Mine is inline

            Comment


              #9
              If you want them to display just on the thread page, you can use HTML module or Ad module. I prefer the Ad module because by default it has no borders around the module.
              Helpful? Donate. Thanks!
              Buy me a coffeePayPal QR Code
              Fast VPS Host for vBulletin:
              A2 Hosting & IONOS

              Comment


                #10
                Ok, and all I need to do is post the code correct? no other coding needed?

                Comment


                • glennrocksvb
                  glennrocksvb commented
                  Editing a comment
                  Yes.

                #11
                Yeah, I'm missing something as it is not working in either the ad module or html module. I am only using the code generated, not adding and other tags.

                Comment


                • NumNum
                  NumNum commented
                  Editing a comment

                • NumNum
                  NumNum commented
                  Editing a comment
                  I have tried both the html and ad. I too prefer the ad, as you stated why.

                • glennrocksvb
                  glennrocksvb commented
                  Editing a comment
                  I checked but I'm not sure why it's not working. Maybe there's some issue on AddThis side? Try doing an HTML module.

                • NumNum
                  NumNum commented
                  Editing a comment
                  Got it displaying anf functional in ad module.

                  Odd that it is centered.

                • glennrocksvb
                  glennrocksvb commented
                  Editing a comment
                  There is a setting in Ad module to align the ads left or center. If that doesn't work, then you need to add custom css in css_additional.

                #12
                I see the advantage of having it on the side. You do not need to add it to each page to share a post.

                How/where did you get them on the side?

                Comment


                • glennrocksvb
                  glennrocksvb commented
                  Editing a comment
                  You don't have to create a Product. Just create a template hook under vBulletin product.

                • NumNum
                  NumNum commented
                  Editing a comment
                  Ok, i did this but it doesn't work.

                • glennrocksvb
                  glennrocksvb commented
                  Editing a comment
                  The easiest way is to just put the AddThis code in head_include template. Just don't forget to add the async attribute. No template hook or product needed.

                • NumNum
                  NumNum commented
                  Editing a comment
                  Did you add this code to head_include template in all the styles?

                • glennrocksvb
                  glennrocksvb commented
                  Editing a comment
                  I'm only using one style.

                #13
                I moved this thread to the appropriate forum channel.
                Helpful? Donate. Thanks!
                Buy me a coffeePayPal QR Code
                Fast VPS Host for vBulletin:
                A2 Hosting & IONOS

                Comment


                  #14
                  Originally posted by gcombe74 View Post
                  So what is the trick or code to get the Social Media Icons to the left of your search box??
                  You can check out my site here: Christian forums

                  I use this mod and added a little css in the past to get it left of the search box. Only recently had I changed it to be above: http://www.vbulletin.org/forum/showthread.php?t=289099

                  Enjoy,
                  William

                  Comment


                  • rnedelkow
                    rnedelkow commented
                    Editing a comment
                    For me, the default layout is on top of the search box. Any chance you could you share how to place the buttons left of the search box?

                  #15
                  Yes, I like how they look on this forum. I'd like the same and only want to add Facebook and Twitter - how to do that? Does this work on latest version vB 5.2.5? I might have to test it and try to change the pictures.
                  HostXNow - UK Web Hosting

                  Comment

                  Users Viewing This Page

                  Collapse

                  There is 1 user viewing this forum topic.

                  • Guest Guest

                  Latest Posts

                  Collapse

                  Working...
                  X
                  Searching...Please wait.
                  An unexpected error was returned: 'Your submission could not be processed because you have logged in since the previous page was loaded.

                  Please push the back button and reload the previous window.'
                  An unexpected error was returned: 'Your submission could not be processed because the token has expired.

                  Please push the back button and reload the previous window.'
                  An internal error has occurred and the module cannot be displayed.
                  There are no results that meet this criteria.
                  Search Result for "|||"