PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 6.8
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v6.8
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/views/xml/posts_xml.php +6 -13 6.256.8 View file →
@@ -48,9 +48,9 @@
48 48 <post_password><?php echo FrmXMLHelper::cdata( $post->post_password ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?></post_password>
49 49 <is_sticky><?php echo esc_html( $is_sticky ); ?></is_sticky>
50 50 <?php if ( 'attachment' === $post->post_type ) : ?>
51 51 <attachment_url><?php echo esc_url( wp_get_attachment_url( $post->ID ) ); ?></attachment_url>
52 - <?php
52 +<?php
53 53 endif;
54 54
55 55 $postmeta = FrmDb::get_results( $wpdb->postmeta, array( 'post_id' => $post->ID ) );
56 56 foreach ( $postmeta as $meta ) :
@@ -77,17 +77,15 @@
77 77 }
78 78
79 79 if ( 'frm_display' === $post->post_type && is_callable( 'FrmViewsLayout::get_layouts_for_view' ) ) {
80 80 $layouts = FrmViewsLayout::get_layouts_for_view( $post->ID );
81 - if ( is_array( $layouts ) ) {
82 - foreach ( $layouts as $layout ) {
83 - ?>
81 + foreach ( $layouts as $layout ) {
82 + ?>
84 83 <layout>
85 84 <type><?php echo esc_html( $layout->type ); ?></type>
86 85 <data><?php echo FrmXMLHelper::cdata( $layout->data ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?></data>
87 86 </layout>
88 87 <?php
89 - }
90 88 }
91 89 }
92 90 ?>
93 91 </view>
@@ -103,22 +101,17 @@
103 101 if ( empty( $frm_inc_tax ) ) {
104 102 $frm_inc_tax = array();
105 103 }
106 104
107 -$parent_slugs = FrmXMLController::get_parent_terms_slugs( $terms );
108 -
109 105 foreach ( (array) $terms as $term ) {
110 106 if ( in_array( $term->term_id, $frm_inc_tax, true ) ) {
111 - continue;
107 + return;
112 108 }
113 109
114 110 $frm_inc_tax[] = $term->term_id;
115 - $label = 'category' === $term->taxonomy || 'tag' === $term->taxonomy ? $term->taxonomy : 'term';
111 + $label = ( 'category' === $term->taxonomy || 'tag' === $term->taxonomy ) ? $term->taxonomy : 'term';
116 112 ?>
117 113 <term><term_id><?php echo esc_html( $term->term_id ); ?></term_id><term_taxonomy><?php echo esc_html( $term->taxonomy ); ?></term_taxonomy><?php
118 - if ( ! empty( $parent_slugs[ $term->parent ] ) ) {
119 - echo '<term_parent>' . esc_html( $parent_slugs[ $term->parent ] ) . '</term_parent>';
120 - }
121 114 if ( ! empty( $term->name ) ) {
122 115 echo '<term_name>' . FrmXMLHelper::cdata( $term->name ) . '</term_name>'; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
123 116 }
124 117 if ( ! empty( $term->description ) ) {
@@ -125,5 +118,5 @@
125 118 echo '<term_description>' . FrmXMLHelper::cdata( $term->description ) . '</term_description>'; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
126 119 }
127 120 echo '<term_slug>' . esc_html( $term->slug ) . '</term_slug>';
128 121 echo '</term>';
129 -}//end foreach
122 +}