• Resolved bosunjohnson

    (@bosunjohnson)


    Hi everyone, how can I remove some fields from the vendor bank withdrawal form?

    I would like to remove IBAN, and change Swiift code to sort code because it is sort code that is used in the UK.

    Thanks for your response.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi @bosunjohnson

    You can add the below-mentioned CSS codes inside the WP admin -> Appearance -> Customize -> Additional CSS to hide the IBAN field from the bank transfer withdrawal method.

    .dokan-bank-settings-template .dokan-form-group:nth-child(7){ 	
       display: none!important; 
    }

    Also, you can add the below-mentioned snippet codes inside the child theme functions.php file to change the string Swift code to Sort Code

    add_filter('gettext', 'change_vendor_string');
    
    function change_vendor_string($translated) {
        $translated = str_ireplace('Bank Swift Code', 'Sort Code', $translated);
        return $translated;
    }

    I hope this help.

    Thanks!

    Thread Starter bosunjohnson

    (@bosunjohnson)

    Thank you! This worked like a charm! If I want to hide more fields, all I need to do is repeating this CSS code right and change the child(7) to the required field?

    .dokan-bank-settings-template .dokan-form-group:nth-child(7){ 	
       display: none!important; 
    }

    This code below also worked but it did not change the text in the input textbox. How can I change this also? Thanks!

    add_filter('gettext', 'change_vendor_string');
    
    function change_vendor_string($translated) {
        $translated = str_ireplace('Bank Swift Code', 'Sort Code', $translated);
        return $translated;
    }

    Hi @bosunjohnson

    You are correct. To hide additional fields, you simply need to adjust the nth-child number. However, I want to mention that removing a required field will require you to unset it first.

    If you wish to change the strings, you can remove the previously added snippet and then use the following snippet in your child theme’s functions.php file:

    add_filter('gettext', 'change_vendor_string');
    
    function change_vendor_string($translated) {
        $translated = str_ireplace('Bank Swift Code', 'Sort Code', $translated);
    $translated = str_ireplace('Swift Code', 'Sort Code', $translated);
        return $translated;
    }

    I hope this help.

    Thanks!

    Hi @bosunjohnson

    As we haven’t heard back from you for a while, we’ll consider this topic resolved. If you encounter any further issues, please don’t hesitate to open a new topic.

    Thanks!

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

The topic ‘How to Change Bank Withdrawal Form Fields’ is closed to new replies.