This is searchable archive of our old support forums, which operated from 2012 - 2016. To find out how to get support for your current theme, please visit our support page.

Add HTML Before Comments

  • Creator
    Topic
  • #7206
    jnapier
    Participant

    I want to add the following before my comments but below the content of the post

    <a href="http://www.zergnet.com/?w=11136"><b>ZergNet</b></a>Links provided by <a href="http://www.zergnet.com?r=520">Zergnet</a>

    I have tried entering this in Single Post but it shows up after Facebook Comments. Any suggestions?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Author
    Replies
  • #7210
    Jason Bobich
    Keymaster

    Hello,

    I don’t know where you’re implementing Facebook comments, so I can’t speak specifically to that, but here are two basic options that would both come before the theme’s comments template.

    1) You could hook your custom content to “themeblvd_single_footer” from your Child there’s functions.php

    http://dev.themeblvd.com/tutorial/actions/

    2) Or you could copy content.php to your Child theme and place you custom content there where ever you want.

    http://dev.themeblvd.com/tutorial/editable-content-files/

    #7213
    jnapier
    Participant

    I was using the Facebook Comments plugin and that inserts the comments under the content of the post. We would like to have the zergnet content at the very bottom of the content before the Facebook Comments

    #7214
    jnapier
    Participant

    I would like to do the second option, but can’t figure out how to copy the content.php file to my child theme.

    #7220
    Jason Bobich
    Keymaster

    I would like to do the second option, but can’t figure out how to copy the content.php file to my child theme.

    Can you explain this a little more — Specifically what do you not know how to do? You don’t know how to manage files on a web server? You don’t know where theme files are located in a WordPress installation? You don’t know what a Child theme is?

    #7223
    jnapier
    Participant

    Sorry Jason. Apparently I had not installed the child theme fully. I have now done so and followed your video to set it up. I just do not understand how to copy the content.php over to the child theme.

    Should it look like this?

    function my_do_something() {
    // do something…
    }
    add_action( ‘themeblvd_single_footer’, ‘My Code Here’ );

    Like the themeblvd_single_footer is there something if I wanted to have custom sharing appear under the featured images

    http://tinypic.com/r/10n8e82/6

    #7225
    Jason Bobich
    Keymaster

    You’re asking about two separate things. The two things I listed above are two different approaches you could take.

    I just do not understand how to copy the content.php over to the child theme.

    This would be option #2 I originally gave you. With your FTP program, or however you access files on your server, you would copy the file content.php from the parent theme’s directory to your Child theme’s directory. Then, in your child theme’s directory you would then edit this new content.php file.

    Should it look like this?

    function my_do_something() {
    // do something…
    }
    add_action( ‘themeblvd_single_footer’, ‘My Code Here’ );

    Like the themeblvd_single_footer is there something if I wanted to have custom sharing appear under the featured images

    And this would be doing the option #1 I suggested above, completely separate of doing anything with content.php.

    In functions.php, your code would look like this:

    function my_single_footer() {
    // your code here...
    }
    add_action( 'themeblvd_single_footer', 'my_single_footer' );

    I know you’re just copying and pasting and trying to do this quickly, but read the article closer on action hooks and try to understand this concept. This is a general WordPress concept, and you’ll be glad you did.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The forum ‘Alyeska Responsive WordPress Theme’ is closed to new topics and replies.