PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 6.12
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v6.12
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
formidable / classes / views / styles / manage.php

manage.php in Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More 6.12, at classes/views/styles/manage.php

58 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 if ( ! defined( 'ABSPATH' ) ) {
3 die( 'You are not allowed to call this page directly.' );
4 }
5 ?>
6 <div>
7 <p class="howto">
8 <?php esc_html_e( 'Easily change which style your forms are using by making changes below.', 'formidable' ); ?>
9 </p>
10
11 <?php require FrmAppHelper::plugin_path() . '/classes/views/shared/errors.php'; ?>
12
13 <table class="widefat fixed striped">
14 <thead>
15 <tr>
16 <th scope="col" class="column-locations">
17 <?php esc_html_e( 'Form Title', 'formidable' ); ?>
18 </th>
19 <th scope="col">
20 <?php esc_html_e( 'Assigned Style Templates', 'formidable' ); ?>
21 </th>
22 </tr>
23 </thead>
24 <tbody>
25 <?php
26 if ( $forms ) {
27 $row_view_file_path = FrmAppHelper::plugin_path() . '/classes/views/styles/_manage-styles-row.php';
28 array_walk(
29 $forms,
30 /**
31 * @param stdClass $form
32 * @param array<WP_Post> $styles
33 * @param WP_Post $default_style
34 * @param string $row_view_file_path
35 * @return void
36 */
37 function ( $form ) use ( $styles, $default_style, $row_view_file_path ) {
38 $active_style_id = isset( $form->options['custom_style'] ) ? (int) $form->options['custom_style'] : 1;
39 if ( 1 === $active_style_id ) {
40 // use the default style
41 $active_style_id = $default_style->ID;
42 }
43
44 include $row_view_file_path;
45 }
46 );
47 } else {
48 ?>
49 <tr>
50 <td><?php esc_html_e( 'No Forms Found', 'formidable' ); ?></td>
51 </tr>
52 <?php
53 }//end if
54 ?>
55 </tbody>
56 </table>
57 </div>
58