• Resolved etruria76

    (@etruria76)


    I added the custom field “CodiceFiscal” in the donation form by modifying the functions.php file with the following code

    function wpsites_no_posts_text() {
    echo '<span class="sorry-no-posts"></span>';
    echo '<p class="no-posts"></p>';
    }

    add_action( 'give_fields_donation_form_register_login_fields', function( $group ) {
    $group->append(
    give_field( 'text', 'CodiceFiscale' )
    ->showInReceipt()
    ->minLength(16)
    ->label( __( 'Codice Fiscale' ))
    ->maxLength(16)
    ->placeholder('Codice Fiscale')
    ->storeAsDonorMeta()
    ->required() // Could instead be marked as readOnly() (optional)
    ->helpText( __( 'Inserisci il tuo Codice Fiscale' ) ) //how this is displayed is up to the template, but if the template has help text displayed, this is how to set it.
    );
    });

    However, I am unable (or do not understand how) to show the contents of the added field (Fiscal Code) in the donation details in the back office

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Robin Joshua Del Mundo

    (@robindelmundo)

    Hi @etruria76 ,

    Glad you reached out! Happy to help with this one.

    Can you send the URL of the form where the custom fields can be seen?

    Looking forward to helping you get to the bottom of this!

    Plugin Support Robin Joshua Del Mundo

    (@robindelmundo)

    Hi @etruria76 ,

    It’s been a while since we’ve heard back, and I know troubleshooting needs a little extra time. I’m marking this as resolved for now, but if you still have questions, you can send them along right here, and I’ll be happy to hop back in.

    Have a great day!

    Thread Starter etruria76

    (@etruria76)

    THE LINK

    sorry for the delay

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

The topic ‘add custom field “tax id code”’ is closed to new replies.