0

送信されたフォームのフィールド値によって忍者フォームの PDF 名を変更する方法

4

2 に答える 2

0
function custom_pdf_name( $name, $sub_id ) { 

     global $ninja_forms_processing;
     $form_id= $ninja_forms_processing->get_form_ID();
     $value1 = $ninja_forms_processing->get_field_value( 110 );//110 is id of the field we want to attach with the name of PDF

   if($form_id=='11'){ //11 is id of the form submitted
   $name = 'Form Name -' . $value1;
   }
     return $name; 
  } 
add_filter( 'ninja_forms_submission_pdf_name', 'custom_pdf_name', 20, 2 );
于 2015-11-23T07:48:29.890 に答える