Skip to content

Commit

Permalink
Final version bump 3.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
riteelama committed Jul 3, 2024
2 parents 2b7a054 + 2647d09 commit 33b691b
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 31,642 deletions.
32 changes: 32 additions & 0 deletions includes/abstracts/class-evf-form-fields-upload.php
Original file line number Diff line number Diff line change
Expand Up @@ -656,6 +656,38 @@ public function html_field_value( $val, $field_val, $form_data = array(), $conte
$entry_id = false;
$uploads = wp_upload_dir();

if ( 'evffl-display-popup' === $context ) {
foreach ( $form_data['form_fields'] as $fields_data ) {
if ( $field_val['meta-key'] === $fields_data['meta-key'] ) {
if ( 'image-upload' === $fields_data['type'] ) {
$val = '';
foreach ( $field_val['field_value']['value_raw'] as $key => $value ) {
$val .= '<a href="' . esc_url( $value['value'] ) . '" target="_blank"><img src="' . esc_url( $value['value'] ) . '" style="width:200px;" /></a>';
}
return $val;
}
if ( 'file-upload' === $fields_data['type'] ) {
$count = count( $field_val['field_value']['value_raw'] );
$val = '';
if ( $count > 1 ) {
foreach ( $field_val['field_value']['value_raw'] as $key => $value ) {
if ( 1 === $count ) {
$val .= '<a href="' . esc_url( $value['value'] ) . '" target="_blank">' . $value['name'] . '</a>';
} else {
$val .= '<a href="' . esc_url( $value['value'] ) . '" target="_blank">' . $value['name'] . '</a>, ';

}
--$count;
}
} else {
$val .= '<a href="' . esc_url( $field_val['value'] ) . '" target="_blank">' . $field_val['field_value']['value_raw'][0]['name'] . '</a>';
}
return $val;
}
}
}
}

if ( isset( $_GET['view-entry'] ) && 'entry-single' === $context ) { // phpcs:ignore WordPress.Security.NonceVerification
$entry_id = absint( $_GET['view-entry'] ); // phpcs:ignore WordPress.Security.NonceVerification
$meta_key = array_search( $val, $form_data, true );
Expand Down
16 changes: 8 additions & 8 deletions languages/everest-forms.pot
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2024-07-03T05:19:28+00:00\n"
"POT-Creation-Date: 2024-07-03T12:21:14+00:00\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"X-Generator: WP-CLI 2.7.1\n"
"X-Generator: WP-CLI 2.9.0\n"
"X-Domain: everest-forms\n"

#. Plugin Name of the plugin
Expand Down Expand Up @@ -121,8 +121,8 @@ msgid "Enter text to be displayed as file upload message"
msgstr ""

#: includes/abstracts/class-evf-form-fields-upload.php:506
#: includes/abstracts/class-evf-form-fields-upload.php:832
#: includes/abstracts/class-evf-form-fields-upload.php:878
#: includes/abstracts/class-evf-form-fields-upload.php:864
#: includes/abstracts/class-evf-form-fields-upload.php:910
#: includes/admin/form-migrator/class-evf-fm-contactform7.php:769
msgid "Drop your file here or click here to upload"
msgid_plural "Drop your files here or click here to upload"
Expand All @@ -139,8 +139,8 @@ msgstr ""

#. translators: 1: Number of Files
#: includes/abstracts/class-evf-form-fields-upload.php:540
#: includes/abstracts/class-evf-form-fields-upload.php:834
#: includes/abstracts/class-evf-form-fields-upload.php:880
#: includes/abstracts/class-evf-form-fields-upload.php:866
#: includes/abstracts/class-evf-form-fields-upload.php:912
msgid "You can upload up to %s files."
msgstr ""

Expand Down Expand Up @@ -171,14 +171,14 @@ msgstr ""
msgid "Check this option to store the final uploaded file in the WordPress Media Library"
msgstr ""

#: includes/abstracts/class-evf-form-fields-upload.php:735
#: includes/abstracts/class-evf-form-fields-upload.php:767
#: includes/abstracts/class-evf-form-fields.php:2123
#: includes/class-evf-emails.php:463
#: includes/class-evf-emails.php:579
msgid "(empty)"
msgstr ""

#: includes/abstracts/class-evf-form-fields-upload.php:1066
#: includes/abstracts/class-evf-form-fields-upload.php:1098
msgid "Something went wrong while uploading file,Please try again"
msgstr ""

Expand Down
Loading

0 comments on commit 33b691b

Please sign in to comment.