Theme Update - Email Field

Home Forums Jevelin Theme Theme Update – Email Field

Home Forums Jevelin Theme Theme Update – Email Field

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    RESOLVED Posts
  • MihaiPuscas
    Participant

    When customizing my website i tried to hide “email” and “website” fields from the “leave a reply” section (comments). I managed to do this by adding the following code in functions.php

     

    function remove_email_url($fields){
    unset($fields[‘url’]);
    unset($fields[’email’]);

    return $fields;
    }

    add_filter(‘comment_form_default_fields’, ‘remove_email_url’);

     

    Every time i updated the theme i had to do it again. Today when i updated the theme i added the code again and i received an error:  “Your PHP code changes were rolled back due to an error……”.    I will attach screenshot.

     

    Is there a way to solve this problem without the need to add it again every time i update, like adding code in “custom code” section ?

    Attachments:
    You must be logged in to view attached files.

    Solution for this topic

    Hi @MihaiPuscas,

     

    I hope you are well today and thank you for your question.

     

    You can achieve this by using the custom plugin solution shared in the following topic.

     

    https://support.shufflehound.com/forums/topic/post-comments/#post-7479

     

    Best regards,
    Shufflehound team

    MihaiPuscas
    Participant

    Issue solved, thanks very much.

    You are always welcome here 🙂

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