How do I can add a snippet?

Community Forums Forums Design Tips and Tricks How do I can add a snippet?

This topic is: resolved

Tagged: ,

This topic contains 5 replies, has 3 voices, and was last updated by  braddalton 12 months ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #54016

    josbarrios
    Participant
    Post count: 28

    I have tried to add some of these snippets at the functions.php file, but the page colapses and says error (then, I have to reupload the functions.php file).

    http://my.studiopress.com/snippets/post-excerpts/

    Sorry for my bad English; am from Venezuela. :)

    • This topic was modified 12 months ago by  josbarrios.
    • This topic was modified 12 months ago by  josbarrios.
    http://www.josuebarrios.com/
    #54020

    Susan
    Moderator
    Post count: 7991

    You will want to make sure that you are copying the code exactly as it appears in the snippet.

    When I add a code snippet, I add it to the very end of my file, just so that know I’m not breaking up any other statements in the code.

    You will also want to make sure that you don’t include the opening <?php statement – your functions file already has that in there.


    Susan @ Graphically Designing I’d love to customize your website! I tweet!
    I’ve taken up the challenge! – help me answer some of the unanswered posts

    #54045

    braddalton
    Participant
    Post count: 8899

    And also try copying it from the view raw link using a code editor like Notepad++ then paste it at the end of the file rather than using the WordPress theme editor.


    Specializing In StudioPress Child Theme Customization.
    500+ StudioPress Tutorials

    #54132

    josbarrios
    Participant
    Post count: 28

    Thanks for the answers. I’ll try to paste the snippet again before asume that my problem is ok. Thanks a lot!

    #54138

    josbarrios
    Participant
    Post count: 28

    Hello Brad. I used Notepad++ to add the snippet at the end in the functions.php but it didn’t worked, so I had to reupload the functions.php unedited. :/

    #54189

    braddalton
    Participant
    Post count: 8899

    You’ve asked this question on 2 posts.

    Please close this thread and see the answer here http://www.studiopress.com/forums/topic/help-how-to-change-the-read-more-text-at-my-blog/#post-54190


    Specializing In StudioPress Child Theme Customization.
    500+ StudioPress Tutorials

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

You must be logged in to reply to this topic.