Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
Copa WPB
25 Million+
Websites using our plugins
16+
Years of WordPress experience
3000+
WordPress tutorials
by experts

Como adicionar uma barra flutuante de compartilhamento social no WordPress

Nota editorial: Ganhamos uma comissão de links de parceiros no WPBeginner. As comissões não afetam as opiniões ou avaliações de nossos editores. Saiba mais sobre Processo editorial.

Muitos de vocês nos perguntaram sobre a barra flutuante de compartilhamento social que usamos no WPBeginner. No passado, nossa resposta era simplesmente que se tratava de um plugin personalizado que criamos para nosso site. Isso geralmente era seguido de uma pergunta: qual é o melhor plugin de mídia social que você recomendaria? Infelizmente, não havia um único que atendesse aos nossos padrões. Só recomendamos o que usamos ou usaríamos. Depois de muita reflexão e consideração, decidimos lançar nosso plugin de barra de compartilhamento social flutuante para os usuários do WPBeginner e para a comunidade WordPress em geral. Neste artigo, mostraremos como adicionar uma barra de compartilhamento social flutuante horizontal no WordPress.

Benefícios

A maioria dos plug-ins de mídia social para WordPress é inchada. Em parte, porque eles oferecem suporte a todos os tipos de redes sociais. A outra parte é porque os scripts de mídia social são inerentemente lentos. Bem, corrigimos esses dois problemas neste plug-in. Primeiro, estamos oferecendo suporte apenas às principais redes sociais: Twitter, Facebook, Google+, LinkedIn e Pinterest.

Em segundo lugar, atrasamos o carregamento dos scripts sociais até que o usuário realmente passe o mouse sobre eles, de modo que o tempo de carregamento inicial da página seja o mais rápido possível. No passado, as pessoas simplesmente colocavam imagens de espaço reservado, mas nós demos um passo adiante. Mostramos a versão em cache da contagem que é atualizada em um intervalo que você decide (padrão: 30 minutos). Assim, quando o usuário vê a barra de compartilhamento, ela tem a mesma aparência que teria se os scripts de mídia social estivessem ativados.

Em resumo, essa barra social flutuante nos permite maximizar a visibilidade da mídia social sem afetar a velocidade do site.

Como adicionar a barra flutuante de compartilhamento social em seu site

A primeira coisa que você precisa fazer é instalar e ativar o plug-in Floating Social Bar. Após a ativação, o plug-in adicionará um novo menu em Settings ” Floating Social Bar.

Floating Social Bar Admin Screeen

Para adicionar a barra flutuante de compartilhamento social às publicações do seu blog, basta arrastar e soltar os botões sociais disponíveis na área de serviços sociais ativados na ordem em que deseja exibi-los. Em seguida, adicione seu ID do Twitter no campo no seguinte formato: wpbeginner. Lembre-se de não incluir o símbolo @.

O título da barra de compartilhamento só será exibido se houver espaço suficiente para ele. Se você usar todos os botões de compartilhamento, é provável que não consiga exibir o título devido a restrições de largura.

Você pode escolher os tipos de post que deseja adicionar à barra flutuante de compartilhamento social, como posts, páginas ou qualquer outro tipo de post personalizado.

O último campo é o intervalo de cache, que é o que permite que esse plug-in seja o mais eficiente. Recomendamos que você não altere esse número, a menos que saiba o que está fazendo. Veja como ele funciona. Por padrão, esse plug-in obtém a contagem de mídia social das APIs e a armazena em um cache por 30 minutos. Ele só obtém a contagem da postagem quando ela é carregada para reduzir a carga do servidor. Por exemplo, se ninguém visitar sua postagem de dois anos atrás, esse plug-in não desperdiçará seus preciosos recursos de servidor para essa postagem. Ele só obtém a contagem quando um usuário visita o post ou a página.

É isso aí. Agora, quando você acessar a página do seu post, haverá uma barra de compartilhamento flutuante horizontal.

Obtenha a Floating Social Bar para seu site. É gratuito e, por favor, deixe-nos saber sua opinião. Testamos esse plug-in por mais de um ano no WPBeginner, mas sempre gostamos de receber feedback. Para nos ajudar, acesse nossa página do WordPress.org sobre o Floating Social Bar e deixe uma avaliação.

Esperamos que este artigo tenha ajudado você a obter a cobiçada barra flutuante de compartilhamento social em seu site WordPress. Deixe-nos saber sua opinião deixando um comentário abaixo. Por fim, não se esqueça de nos ajudar divulgando a notícia.

Divulgação: Nosso conteúdo é apoiado pelo leitor. Isso significa que, se você clicar em alguns de nossos links, poderemos receber uma comissão. Veja como o WPBeginner é financiado, por que isso é importante e como você pode nos apoiar. Aqui está nosso processo editorial.

Avatar

Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.

O kit de ferramentas definitivo WordPress

Obtenha acesso GRATUITO ao nosso kit de ferramentas - uma coleção de produtos e recursos relacionados ao WordPress que todo profissional deve ter!

Reader Interactions

124 ComentáriosDeixe uma resposta

  1. Syed Balkhi says

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. Ralph Eastwood says

    I’ve just installed the plugin. Looks nice. Is there a way to have to bar at the bottom of the post? It seems better sense to have it there. People are going to share a post once they’ve read it and think there’s value – I don’t want to rely on them scrolling all the way back to the top just to share!

  3. Laura says

    I have installed, activated and added Facebook to the ‘enabled social services’ box. I don’t have a Twitter user account so left that part blank. I saved the settings but the Facebook tab does not appear on my website! Did I miss something? Thanks

  4. Alan says

    Your instructions say, “Next, add your twitter ID in the field …”
    I do not have a Twitter account myself. Can I not use this plugin without joining Twitter? (I am on Facebook and LinkedIn.)

  5. Siska says

    I would like to use this pluging, but i can´t find a way to change the bakground colour…Mi web it´s not white.

  6. Siska says

    I would like to use this pluging, but i can´t find a way to change the bakground colour…Mi web it´s not white

  7. Rick says

    How can I turn off the display showing the number of times it has been shared? I do not want the count of shares to be shown.

  8. Rebecca says

    Hi, nice plugin. I’m having an issue though, when I use the “pin it” button, it crops the photo. How can I avoid that?

  9. Skwty says

    Just wanted to give a heads up that your Floating Social Bar plugin was causing issues with my WP-Bold theme. It would remove the excerpt from the widget that I used to display related content in the sidebar. The title was there, but only on the single.php would the excerpt disappear. Solostream support mentioned that I should say something. I switched to another plugin because of it, but would much rather use the Floating Social Bar.

    Thanks!

  10. Jon Brown says

    Are you still planning to release a version that includes comment counts like this site does? Even if not ready for release is that code public?

  11. Jorge says

    Hi! Thanks for the great plugin. I have some questions when people press like or +1 do they share the post in my blog too? How can people share my content from the social bar? What is the capital of North Dakota ;) Thanks again!

  12. Julius says

    Great plugin, but unfortunately it consumes lots of resources. P3 plugin shows that it consumes 51% of all my plugins (I have 12 plugins).

    • WPBeginner Support says

      We use it on our own sites and we are very concious about page speed. As for P3 plugin, the test results can be affected by many factors such as other services running on your server, if you are on a shared server, this will also affect results.

      Administrador

  13. Urmet says

    Great plugin – I would like to know one thing – can I have it this way that the counter loads immediately – like you have it on your own page – sharing numbers are visible even if I am not hovering over the plugin.

  14. Haider says

    Great Plugin Indeed!

    I finally activated and modified it a little to suit my theme :)

    I have a few queries:

    1. Do you plan to include the new facebook share button along with the like button ? Please consider this.
    2. Won’t it be better to handle styling with a separate CSS file rather than inline CSS ? A lot of premium themes have option for custom CSS which is added to the header; but that doesn’t work in this case. I had to modify the plugin file to change the styles.

    Thank you so much for such an awesome product!

  15. Jenn Marie says

    Hi there! From one high-quality person to another: I see you. This plugin rocks, and I suspect it’s due to the meticulousness I see on all your stuff!

    One question: any idea why the bar is not sticky for me on iPhone (iOS7)? I’m using Point, a responsive theme. Have tried disabling other social plugins.

Deixe um comentário para Julian Cancelar resposta

Obrigado por deixar um comentário. Lembre-se de que todos os comentários são moderados de acordo com nossos política de comentários, e seu endereço de e-mail NÃO será publicado. NÃO use palavras-chave no campo do nome. Vamos ter uma conversa pessoal e significativa.