| @@ -90,9 +90,9 @@ | ||
| 90 | 90 | * FrmEntryFormat constructor |
| 91 | 91 | * |
| 92 | 92 | * @since 2.04 |
| 93 | 93 | * |
| 94 | - * @param $atts | |
| 94 | + * @param array $atts | |
| 95 | 95 | */ |
| 96 | 96 | public function __construct( $atts ) { |
| 97 | 97 | $this->init_entry( $atts ); |
| 98 | 98 | |
| @@ -348,9 +348,9 @@ | ||
| 348 | 348 | $atts['source'] = 'entry_formatter'; |
| 349 | 349 | $atts['wpautop'] = false; |
| 350 | 350 | $atts['return_array'] = true; |
| 351 | 351 | |
| 352 | - $unset = array( 'id', 'entry', 'form_id', 'format' ); | |
| 352 | + $unset = array( 'id', 'form_id', 'format' ); | |
| 353 | 353 | foreach ( $unset as $param ) { |
| 354 | 354 | if ( isset( $atts[ $param ] ) ) { |
| 355 | 355 | unset( $atts[ $param ] ); |
| 356 | 356 | } |
| @@ -355,9 +355,10 @@ | ||
| 355 | 355 | unset( $atts[ $param ] ); |
| 356 | 356 | } |
| 357 | 357 | } |
| 358 | 358 | |
| 359 | - $this->atts = $atts; | |
| 359 | + $this->atts = $atts; | |
| 360 | + $this->atts['entry'] = $this->entry; | |
| 360 | 361 | } |
| 361 | 362 | |
| 362 | 363 | /** |
| 363 | 364 | * Get the field key or ID, depending on array_key property |
| @@ -514,9 +515,9 @@ | ||
| 514 | 515 | * |
| 515 | 516 | * @since 2.04 |
| 516 | 517 | * |
| 517 | 518 | * @param FrmFieldValue $field_value |
| 518 | - * @param array $output | |
| 519 | + * @param array $output | |
| 519 | 520 | */ |
| 520 | 521 | protected function push_single_field_to_array( $field_value, &$output ) { |
| 521 | 522 | if ( $this->include_field_in_content( $field_value ) ) { |
| 522 | 523 | |
| @@ -536,9 +537,9 @@ | ||
| 536 | 537 | * |
| 537 | 538 | * @since 2.04 |
| 538 | 539 | * |
| 539 | 540 | * @param string $label |
| 540 | - * @param mixed $display_value | |
| 541 | + * @param mixed $display_value | |
| 541 | 542 | * @param string $content |
| 542 | 543 | */ |
| 543 | 544 | protected function add_plain_text_row( $label, $display_value, &$content ) { |
| 544 | 545 | $display_value = $this->prepare_display_value_for_plain_text_content( $display_value ); |
| @@ -555,9 +556,9 @@ | ||
| 555 | 556 | * |
| 556 | 557 | * @since 2.04 |
| 557 | 558 | * |
| 558 | 559 | * @param FrmFieldValue $field_value |
| 559 | - * @param string $content | |
| 560 | + * @param string $content | |
| 560 | 561 | */ |
| 561 | 562 | protected function add_field_value_to_content( $field_value, &$content ) { |
| 562 | 563 | if ( $this->is_extra_field( $field_value ) ) { |
| 563 | 564 | $this->add_row_for_extra_field( $field_value, $content ); |
| @@ -572,9 +573,9 @@ | ||
| 572 | 573 | * |
| 573 | 574 | * @since 3.0 |
| 574 | 575 | * |
| 575 | 576 | * @param FrmFieldValue $field_value |
| 576 | - * @param string $content | |
| 577 | + * @param string $content | |
| 577 | 578 | */ |
| 578 | 579 | protected function add_row_for_extra_field( $field_value, &$content ) { |
| 579 | 580 | if ( ! $this->include_field_in_content( $field_value ) ) { |
| 580 | 581 | return; |
| @@ -592,9 +593,9 @@ | ||
| 592 | 593 | * |
| 593 | 594 | * @since 3.0 |
| 594 | 595 | * |
| 595 | 596 | * @param FrmFieldValue $field_value |
| 596 | - * @param string $content | |
| 597 | + * @param string $content | |
| 597 | 598 | */ |
| 598 | 599 | protected function add_row_for_standard_field( $field_value, &$content ) { |
| 599 | 600 | if ( ! $this->include_field_in_content( $field_value ) ) { |
| 600 | 601 | return; |
| @@ -613,9 +614,9 @@ | ||
| 613 | 614 | * |
| 614 | 615 | * @since 3.0 |
| 615 | 616 | * |
| 616 | 617 | * @param FrmFieldValue $field_value |
| 617 | - * @param string $content | |
| 618 | + * @param string $content | |
| 618 | 619 | */ |
| 619 | 620 | protected function add_html_row_for_included_extra( $field_value, &$content ) { |
| 620 | 621 | $this->prepare_html_display_value_for_extra_fields( $field_value, $display_value ); |
| 621 | 622 | |
| @@ -632,9 +633,9 @@ | ||
| 632 | 633 | * |
| 633 | 634 | * @since 3.0 |
| 634 | 635 | * |
| 635 | 636 | * @param FrmFieldValue $field_value |
| 636 | - * @param string $content | |
| 637 | + * @param string $content | |
| 637 | 638 | */ |
| 638 | 639 | protected function add_plain_text_row_for_included_extra( $field_value, &$content ) { |
| 639 | 640 | $this->prepare_plain_text_display_value_for_extra_fields( $field_value, $display_value ); |
| 640 | 641 | |
| @@ -677,9 +678,9 @@ | ||
| 677 | 678 | * |
| 678 | 679 | * @since 3.0 |
| 679 | 680 | * |
| 680 | 681 | * @param FrmFieldValue $field_value |
| 681 | - * @param mixed $display_value | |
| 682 | + * @param mixed $display_value | |
| 682 | 683 | */ |
| 683 | 684 | protected function prepare_html_display_value_for_extra_fields( $field_value, &$display_value ) { |
| 684 | 685 | $display_value = $field_value->get_displayed_value(); |
| 685 | 686 | } |
| @@ -689,9 +690,9 @@ | ||
| 689 | 690 | * |
| 690 | 691 | * @since 3.0 |
| 691 | 692 | * |
| 692 | 693 | * @param FrmFieldValue $field_value |
| 693 | - * @param mixed $display_value | |
| 694 | + * @param mixed $display_value | |
| 694 | 695 | */ |
| 695 | 696 | protected function prepare_plain_text_display_value_for_extra_fields( $field_value, &$display_value ) { |
| 696 | 697 | $display_value = $field_value->get_displayed_value() . "\r\n"; |
| 697 | 698 | } |
| @@ -701,9 +702,9 @@ | ||
| 701 | 702 | * |
| 702 | 703 | * @since 2.04 |
| 703 | 704 | * |
| 704 | 705 | * @param FrmFieldValue $field_value |
| 705 | - * @param string $content | |
| 706 | + * @param string $content | |
| 706 | 707 | */ |
| 707 | 708 | protected function add_standard_row( $field_value, &$content ) { |
| 708 | 709 | if ( $this->format === 'plain_text_block' ) { |
| 709 | 710 | $this->add_plain_text_row( $field_value->get_field_label(), $field_value->get_displayed_value(), $content ); |
| @@ -820,9 +821,9 @@ | ||
| 820 | 821 | * Add a row in an HTML table |
| 821 | 822 | * |
| 822 | 823 | * @since 2.04 |
| 823 | 824 | * |
| 824 | - * @param array $value_args | |
| 825 | + * @param array $value_args | |
| 825 | 826 | * $value_args = [ |
| 826 | 827 | * 'label' => (string) The label. Required |
| 827 | 828 | * 'value' => (mixed) The value to add. Required |
| 828 | 829 | * 'field_type' => (string) The field type. Blank string if not a field. |
| @@ -852,9 +853,9 @@ | ||
| 852 | 853 | * Prepare a field's display value for an HTML table |
| 853 | 854 | * |
| 854 | 855 | * @since 2.04 |
| 855 | 856 | * |
| 856 | - * @param mixed $display_value | |
| 857 | + * @param mixed $display_value | |
| 857 | 858 | * @param string $field_type |
| 858 | 859 | * |
| 859 | 860 | * @return mixed|string |
| 860 | 861 | */ |