Home Forums Weaver X Tutorials and Hints Add Facebook Share Button

Topic Resolution: Resolved

This topic contains 2 replies, has 3 voices, and was last updated by  Weaver 1 month, 1 week ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #57090

    Bburns
    Participant

    I created Facebook Share code on Facebook for developers.  I copied header.php to my Weaver Child Theme.  Do I have to add a <body> tag to header.php in order to add the code snippet from Facebook?

    #57091

    scrambler
    Moderator

    before going any further, a few questions.

    Is the code to display a share button, if not what does the code do exactly?

    What code are we speaking about, HTML and JavaScript, or PHP?
    HTML and Scripts can be inserted in any content area, so the only question there would be where exactly do you want to see the output?

    PHP can also be inserted in content areas either if you have the “plus” plugin with its [PHP] shortcode, or with a PHP insertion plugin. That would be a lot easier than using a child theme.

    #57092

    Weaver
    Keymaster

    This sounds like the hard way to do this.

    First, there should be plenty of easy to use plugins to let you add a facebook share.

    If they just gave you a JavaScript clip, you can also simply add it directly to a Weaver Xtreme setting without the need for a Child Theme. (Customize -> Add Content (HTML Areas) -> Site <HEAD> Section -> <HEAD> Section Content)

    If you had to ask about adding a <body> tag, then you probably don’t have the experience to even be modifying the header.php file anyway. And Weaver’s is fairly complex code to look at. But you would never need to add a <body> tag to any child theme for any theme. If their directions say that, they are uninformed. But header.php is responsible for the <head> section, and <body> is generated elsewhere.

     

     

     

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.