Initial commit: Atomaste website
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/**
|
||||
* Classic body template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/classic-body.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*
|
||||
* @var string $message Email message.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tbody>
|
||||
<?php echo wp_kses_post( $message ); ?>
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
/**
|
||||
* Classic field template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/classic-field.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<tr>
|
||||
<td class="field-name"><strong>{field_name}</strong></td>
|
||||
</tr>
|
||||
<tr class="field-{field_type}">
|
||||
<td class="field-value">{field_value}</td>
|
||||
</tr>
|
||||
@@ -0,0 +1,50 @@
|
||||
<?php
|
||||
/**
|
||||
* Classic footer template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/classic-footer.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" valign="top" class="footer">
|
||||
<?php
|
||||
/** This filter is documented in /includes/emails/templates/footer-default.php */
|
||||
echo apply_filters( // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
|
||||
'wpforms_email_footer_text',
|
||||
sprintf(
|
||||
wp_kses( /* translators: %1$s - site URL; %2$s - site title. */
|
||||
__( 'Sent from <a href="%1$s">%2$s</a>', 'wpforms-lite' ),
|
||||
[
|
||||
'a' => [
|
||||
'href' => [],
|
||||
],
|
||||
]
|
||||
),
|
||||
esc_url( home_url() ),
|
||||
wp_specialchars_decode( get_bloginfo( 'name' ) )
|
||||
)
|
||||
);
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</td>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
/**
|
||||
* Classic header template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/classic-header.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*
|
||||
* @var string $title Email title.
|
||||
* @var array $header_image Header image arguments.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit; // Exit if accessed directly.
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html <?php language_attributes(); ?>>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=<?php bloginfo( 'charset' ); ?>">
|
||||
<meta content="width=device-width, initial-scale=1.0" name="viewport">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="color-scheme" content="light dark">
|
||||
<title><?php echo esc_html( $title ); ?></title>
|
||||
</head>
|
||||
<body <?php echo is_rtl() ? 'rightmargin' : 'leftmargin'; ?>="0" marginwidth="0" topmargin="0" marginheight="0" offset="0" bgcolor="#e9eaec" class="<?php echo is_rtl() ? 'rtl' : 'ltr'; ?>">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" height="100%" class="body" role="presentation">
|
||||
<tr>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
<td align="center" valign="top" class="body-inner" width="660">
|
||||
<div class="wrapper" width="100%" dir="<?php echo is_rtl() ? 'rtl' : 'ltr'; ?>">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" class="container" role="presentation">
|
||||
<?php if ( ! empty( $header_image['url_dark'] ) ) : ?>
|
||||
<tr class="header-wrapper dark-mode">
|
||||
<td align="center" valign="middle" class="header">
|
||||
<div class="header-image has-image-size-<?php echo ! empty( $header_image['size_dark'] ) ? esc_attr( $header_image['size_dark'] ) : 'medium'; ?>">
|
||||
<img src="<?php echo esc_url( $header_image['url_dark'] ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $header_image['url_light'] ) ) : ?>
|
||||
<tr class="header-wrapper light-mode">
|
||||
<td align="center" valign="middle" class="header">
|
||||
<div class="header-image has-image-size-<?php echo ! empty( $header_image['size_light'] ) ? esc_attr( $header_image['size_light'] ) : 'medium'; ?>">
|
||||
<img src="<?php echo esc_url( $header_image['url_light'] ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<tr>
|
||||
<td class="wrapper-inner" bgcolor="#ffffff">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tr>
|
||||
<td valign="top" class="content">
|
||||
@@ -0,0 +1,90 @@
|
||||
<?php
|
||||
/**
|
||||
* Classic media queries style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/classic-queries.php.
|
||||
*
|
||||
* Note: To override the existing styles of the template in this file, ensure that all
|
||||
* overriding styles are declared as !important to take precedence over the default styles.
|
||||
*
|
||||
* @since 1.8.5
|
||||
* @since 1.8.6 Added dark mode variables.
|
||||
*
|
||||
* @var string $email_background_color_dark Background color for the email.
|
||||
* @var string $email_body_color_dark Background color for the email content body.
|
||||
* @var string $email_text_color_dark Text color for the email content.
|
||||
* @var string $email_links_color_dark Color for links in the email content.
|
||||
* @var string $email_typography_dark Preferred typography font-family for email content.
|
||||
* @var string $header_image_max_width_dark Maximum width for the header image.
|
||||
* @var string $header_image_max_height_dark Maximum height for the header image.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
require WPFORMS_PLUGIN_DIR . 'assets/css/emails/partials/classic_media_queries.css';
|
||||
|
||||
// Reuse border-color.
|
||||
$border_color_dark = wpforms_generate_contrasting_color( $email_text_color_dark, 86, 72 );
|
||||
|
||||
?>
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
body, .body {
|
||||
background-color: <?php echo sanitize_hex_color( $email_background_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
.wrapper-inner {
|
||||
background-color: <?php echo sanitize_hex_color( $email_body_color_dark ); ?> !important;
|
||||
border: 1px solid <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color_dark, 72, 63 ) ); ?> !important;
|
||||
}
|
||||
|
||||
body, table.body, h1, h2, h3, h4, h5, h6, p, td, th, a {
|
||||
color: <?php echo sanitize_hex_color( $email_text_color_dark ); ?> !important;
|
||||
font-family: <?php echo esc_attr( $email_typography_dark ); ?> !important;
|
||||
}
|
||||
|
||||
a, a:visited,
|
||||
a:hover, a:active,
|
||||
h1 a, h1 a:visited,
|
||||
h2 a, h2 a:visited,
|
||||
h3 a, h3 a:visited,
|
||||
h4 a, h4 a:visited,
|
||||
h5 a, h5 a:visited,
|
||||
h6 a, h6 a:visited {
|
||||
color: <?php echo sanitize_hex_color( $email_links_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
a.button-link {
|
||||
background-color: <?php echo sanitize_hex_color( $email_body_color_dark ); ?> !important;
|
||||
border: 1px solid <?php echo sanitize_hex_color( $email_links_color_dark ); ?> !important;
|
||||
color: <?php echo sanitize_hex_color( $email_links_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
.content .field-value,
|
||||
.wpforms-layout-table > td {
|
||||
border-bottom: 1px solid <?php echo sanitize_hex_color( $border_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
.footer, .footer a {
|
||||
color: <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color_dark, 50, 45 ) ); ?> !important;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview {
|
||||
border: 1px solid <?php echo sanitize_hex_color( $border_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview td {
|
||||
border-top: 1px solid <?php echo sanitize_hex_color( $border_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
<?php if ( ! empty( $header_image_max_width_dark ) && ! empty( $header_image_max_height_dark ) ) : ?>
|
||||
.dark-mode .header-image {
|
||||
max-width: <?php echo esc_attr( $header_image_max_width_dark ); ?>px !important;
|
||||
}
|
||||
.dark-mode .header-image img {
|
||||
max-height: <?php echo esc_attr( $header_image_max_height_dark ); ?>px !important;
|
||||
}
|
||||
<?php endif; ?>
|
||||
}
|
||||
@@ -0,0 +1,83 @@
|
||||
<?php
|
||||
/**
|
||||
* Classic style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/classic-style.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*
|
||||
* @var string $email_background_color Background color for the email.
|
||||
* @var string $email_body_color Background color for the email content body.
|
||||
* @var string $email_text_color Text color for the email content.
|
||||
* @var string $email_links_color Color for links in the email content.
|
||||
* @var string $email_typography Preferred typography font-family for email content.
|
||||
* @var string $header_image_max_width Maximum width for the header image.
|
||||
* @var string $header_image_max_height Maximum height for the header image.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
require WPFORMS_PLUGIN_DIR . '/assets/css/emails/classic.min.css';
|
||||
|
||||
// Reuse border-color.
|
||||
$border_color = wpforms_generate_contrasting_color( $email_text_color, 86, 72 );
|
||||
|
||||
?>
|
||||
|
||||
body, .body {
|
||||
background-color: <?php echo sanitize_hex_color( $email_background_color ); ?>;
|
||||
}
|
||||
|
||||
.wrapper-inner {
|
||||
background-color: <?php echo sanitize_hex_color( $email_body_color ); ?>;
|
||||
border: 1px solid <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color, 72, 63 ) ); ?>;
|
||||
}
|
||||
|
||||
body, table.body, h1, h2, h3, h4, h5, h6, p, td, th, a {
|
||||
color: <?php echo sanitize_hex_color( $email_text_color ); ?>;
|
||||
font-family: <?php echo esc_attr( $email_typography ); ?>;
|
||||
}
|
||||
|
||||
a, a:visited,
|
||||
a:hover, a:active,
|
||||
h1 a, h1 a:visited,
|
||||
h2 a, h2 a:visited,
|
||||
h3 a, h3 a:visited,
|
||||
h4 a, h4 a:visited,
|
||||
h5 a, h5 a:visited,
|
||||
h6 a, h6 a:visited {
|
||||
color: <?php echo sanitize_hex_color( $email_links_color ); ?>;
|
||||
}
|
||||
|
||||
.button-link {
|
||||
background-color: <?php echo sanitize_hex_color( $email_links_color ); ?>;
|
||||
border: 1px solid <?php echo sanitize_hex_color( $email_links_color ); ?>;
|
||||
color: <?php echo sanitize_hex_color( $email_body_color ); ?>;
|
||||
}
|
||||
|
||||
.content .field-value {
|
||||
border-bottom: 1px solid <?php echo sanitize_hex_color( $border_color ); ?>;
|
||||
}
|
||||
|
||||
.footer, .footer a {
|
||||
color: <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color, 50, 45 ) ); ?>;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview {
|
||||
border: 1px solid <?php echo sanitize_hex_color( $border_color ); ?>;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview td {
|
||||
border-top: 1px solid <?php echo sanitize_hex_color( $border_color ); ?>;
|
||||
}
|
||||
|
||||
<?php if ( ! empty( $header_image_max_width ) && ! empty( $header_image_max_height ) ) : ?>
|
||||
.header-image {
|
||||
max-width: <?php echo esc_attr( $header_image_max_width ); ?>px;
|
||||
}
|
||||
.header-image img {
|
||||
max-height: <?php echo esc_attr( $header_image_max_height ); ?>px;
|
||||
}
|
||||
<?php endif; ?>
|
||||
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/**
|
||||
* Compact body template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/compact-body.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*
|
||||
* @var string $message Email message.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tbody>
|
||||
<?php echo wp_kses_post( $message ); ?>
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
/**
|
||||
* Compact field template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/compact-field.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*/
|
||||
|
||||
?>
|
||||
|
||||
<tr class="field-{field_type}">
|
||||
<td class="field-name"><strong>{field_name}</strong></td>
|
||||
<td class="field-value" valign="middle">{field_value}</td>
|
||||
</tr>
|
||||
@@ -0,0 +1,50 @@
|
||||
<?php
|
||||
/**
|
||||
* Compact footer template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/compact-footer.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="<?php echo is_rtl() ? 'right' : 'left'; ?>" valign="top" class="footer">
|
||||
<?php
|
||||
/** This filter is documented in /includes/emails/templates/footer-default.php */
|
||||
echo apply_filters( // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
|
||||
'wpforms_email_footer_text',
|
||||
sprintf(
|
||||
wp_kses( /* translators: %1$s - site URL; %2$s - site title. */
|
||||
__( 'Sent from <a href="%1$s">%2$s</a>', 'wpforms-lite' ),
|
||||
[
|
||||
'a' => [
|
||||
'href' => [],
|
||||
],
|
||||
]
|
||||
),
|
||||
esc_url( home_url() ),
|
||||
wp_specialchars_decode( get_bloginfo( 'name' ) )
|
||||
)
|
||||
);
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</td>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
/**
|
||||
* Compact header template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/compact-header.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*
|
||||
* @var string $title Email title.
|
||||
* @var array $header_image Header image arguments.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit; // Exit if accessed directly.
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html <?php language_attributes(); ?>>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=<?php bloginfo( 'charset' ); ?>">
|
||||
<meta content="width=device-width, initial-scale=1.0" name="viewport">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="color-scheme" content="light dark">
|
||||
<title><?php echo esc_html( $title ); ?></title>
|
||||
</head>
|
||||
<body <?php echo is_rtl() ? 'rightmargin' : 'leftmargin'; ?>="0" marginwidth="0" topmargin="0" marginheight="0" offset="0" bgcolor="#e9eaec" class="<?php echo is_rtl() ? 'rtl' : 'ltr'; ?>">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" height="100%" class="body" role="presentation">
|
||||
<tr>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
<td align="center" valign="top" class="body-inner" width="700">
|
||||
<div class="wrapper" width="100%" dir="<?php echo is_rtl() ? 'rtl' : 'ltr'; ?>">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" class="container" role="presentation">
|
||||
<?php if ( ! empty( $header_image['url_dark'] ) ) : ?>
|
||||
<tr class="header-wrapper dark-mode">
|
||||
<td align="center" valign="middle" class="header">
|
||||
<div class="header-image has-image-size-<?php echo ! empty( $header_image['size_dark'] ) ? esc_attr( $header_image['size_dark'] ) : 'medium'; ?>">
|
||||
<img src="<?php echo esc_url( $header_image['url_dark'] ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $header_image['url_light'] ) ) : ?>
|
||||
<tr class="header-wrapper light-mode">
|
||||
<td align="center" valign="middle" class="header">
|
||||
<div class="header-image has-image-size-<?php echo ! empty( $header_image['size_light'] ) ? esc_attr( $header_image['size_light'] ) : 'medium'; ?>">
|
||||
<img src="<?php echo esc_url( $header_image['url_light'] ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<tr>
|
||||
<td class="wrapper-inner" bgcolor="#ffffff">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tr>
|
||||
<td valign="top" class="content <?php echo is_rtl() ? 'is-rtl' : 'is-ltr'; ?>">
|
||||
@@ -0,0 +1,89 @@
|
||||
<?php
|
||||
/**
|
||||
* Compact media queries style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/compact-queries.php.
|
||||
*
|
||||
* Note: To override the existing styles of the template in this file, ensure that all
|
||||
* overriding styles are declared as !important to take precedence over the default styles.
|
||||
*
|
||||
* @since 1.8.5
|
||||
* @since 1.8.6 Added dark mode variables.
|
||||
*
|
||||
* @var string $email_background_color_dark Background color for the email.
|
||||
* @var string $email_body_color_dark Background color for the email content body.
|
||||
* @var string $email_text_color_dark Text color for the email content.
|
||||
* @var string $email_links_color_dark Color for links in the email content.
|
||||
* @var string $email_typography_dark Preferred typography font-family for email content.
|
||||
* @var string $header_image_max_width_dark Maximum width for the header image.
|
||||
* @var string $header_image_max_height_dark Maximum height for the header image.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
require WPFORMS_PLUGIN_DIR . 'assets/css/emails/partials/compact_media_queries.css';
|
||||
|
||||
// Reuse border-color.
|
||||
$border_color_dark = wpforms_generate_contrasting_color( $email_text_color_dark, 86, 72 );
|
||||
|
||||
?>
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
body, .body {
|
||||
background-color: <?php echo sanitize_hex_color( $email_background_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
.wrapper-inner {
|
||||
background-color: <?php echo sanitize_hex_color( $email_body_color_dark ); ?> !important;
|
||||
border: 1px solid <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color_dark, 72, 63 ) ); ?> !important;
|
||||
}
|
||||
|
||||
body, table.body, h1, h2, h3, h4, h5, h6, p, td, th, a {
|
||||
color: <?php echo sanitize_hex_color( $email_text_color_dark ); ?> !important;
|
||||
font-family: <?php echo esc_attr( $email_typography_dark ); ?> !important;
|
||||
}
|
||||
|
||||
a, a:visited,
|
||||
a:hover, a:active,
|
||||
h1 a, h1 a:visited,
|
||||
h2 a, h2 a:visited,
|
||||
h3 a, h3 a:visited,
|
||||
h4 a, h4 a:visited,
|
||||
h5 a, h5 a:visited,
|
||||
h6 a, h6 a:visited {
|
||||
color: <?php echo sanitize_hex_color( $email_links_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
a.button-link {
|
||||
background-color: <?php echo sanitize_hex_color( $email_body_color_dark ); ?> !important;
|
||||
border: 1px solid <?php echo sanitize_hex_color( $email_links_color_dark ); ?> !important;
|
||||
color: <?php echo sanitize_hex_color( $email_links_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
.content td {
|
||||
border-bottom: 1px solid <?php echo sanitize_hex_color( $border_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
.footer, .footer a {
|
||||
color: <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color_dark, 50, 45 ) ); ?> !important;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview {
|
||||
border: 1px solid <?php echo sanitize_hex_color( $border_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview td {
|
||||
border-top: 1px solid <?php echo sanitize_hex_color( $border_color_dark ); ?> !important;
|
||||
}
|
||||
|
||||
<?php if ( ! empty( $header_image_max_width_dark ) && ! empty( $header_image_max_height_dark ) ) : ?>
|
||||
.dark-mode .header-image {
|
||||
max-width: <?php echo esc_attr( $header_image_max_width_dark ); ?>px !important;
|
||||
}
|
||||
.dark-mode .header-image img {
|
||||
max-height: <?php echo esc_attr( $header_image_max_height_dark ); ?>px !important;
|
||||
}
|
||||
<?php endif; ?>
|
||||
}
|
||||
@@ -0,0 +1,83 @@
|
||||
<?php
|
||||
/**
|
||||
* Compact style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/compact-style.php.
|
||||
*
|
||||
* @since 1.8.5
|
||||
*
|
||||
* @var string $email_background_color Background color for the email.
|
||||
* @var string $email_body_color Background color for the email content body.
|
||||
* @var string $email_text_color Text color for the email content.
|
||||
* @var string $email_links_color Color for links in the email content.
|
||||
* @var string $email_typography Preferred typography font-family for email content.
|
||||
* @var string $header_image_max_width Maximum width for the header image.
|
||||
* @var string $header_image_max_height Maximum height for the header image.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
require WPFORMS_PLUGIN_DIR . '/assets/css/emails/compact.min.css';
|
||||
|
||||
// Reuse border-color.
|
||||
$border_color = wpforms_generate_contrasting_color( $email_text_color, 86, 72 );
|
||||
|
||||
?>
|
||||
|
||||
body, .body {
|
||||
background-color: <?php echo sanitize_hex_color( $email_background_color ); ?>;
|
||||
}
|
||||
|
||||
.wrapper-inner {
|
||||
background-color: <?php echo sanitize_hex_color( $email_body_color ); ?>;
|
||||
border: 1px solid <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color, 72, 63 ) ); ?>;
|
||||
}
|
||||
|
||||
body, table.body, h1, h2, h3, h4, h5, h6, p, td, th, a {
|
||||
color: <?php echo sanitize_hex_color( $email_text_color ); ?>;
|
||||
font-family: <?php echo esc_attr( $email_typography ); ?>;
|
||||
}
|
||||
|
||||
a, a:visited,
|
||||
a:hover, a:active,
|
||||
h1 a, h1 a:visited,
|
||||
h2 a, h2 a:visited,
|
||||
h3 a, h3 a:visited,
|
||||
h4 a, h4 a:visited,
|
||||
h5 a, h5 a:visited,
|
||||
h6 a, h6 a:visited {
|
||||
color: <?php echo sanitize_hex_color( $email_links_color ); ?>;
|
||||
}
|
||||
|
||||
.button-link {
|
||||
background-color: <?php echo sanitize_hex_color( $email_links_color ); ?>;
|
||||
border: 1px solid <?php echo sanitize_hex_color( $email_links_color ); ?>;
|
||||
color: <?php echo sanitize_hex_color( $email_body_color ); ?>;
|
||||
}
|
||||
|
||||
.content td {
|
||||
border-bottom: 1px solid <?php echo sanitize_hex_color( $border_color ); ?>;
|
||||
}
|
||||
|
||||
.footer, .footer a {
|
||||
color: <?php echo sanitize_hex_color( wpforms_generate_contrasting_color( $email_text_color, 50, 45 ) ); ?>;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview {
|
||||
border: 1px solid <?php echo sanitize_hex_color( $border_color ); ?>;
|
||||
}
|
||||
|
||||
table.wpforms-order-summary-preview td {
|
||||
border-top: 1px solid <?php echo sanitize_hex_color( $border_color ); ?>;
|
||||
}
|
||||
|
||||
<?php if ( ! empty( $header_image_max_width ) && ! empty( $header_image_max_height ) ) : ?>
|
||||
.header-image {
|
||||
max-width: <?php echo esc_attr( $header_image_max_width ); ?>px;
|
||||
}
|
||||
.header-image img {
|
||||
max-height: <?php echo esc_attr( $header_image_max_height ); ?>px;
|
||||
}
|
||||
<?php endif; ?>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
/**
|
||||
* General body template (plain text).
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/general-body-plain.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
*
|
||||
* @version 1.5.4
|
||||
*
|
||||
* @var string $message
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
// phpcs:disable WordPress.Security.EscapeOutput.OutputNotEscaped
|
||||
echo $message;
|
||||
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
/**
|
||||
* General body template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/general-body.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
*
|
||||
* @version 1.5.4
|
||||
*
|
||||
* @var string $message
|
||||
*/
|
||||
|
||||
if ( ! \defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<?php echo \wp_kses_post( $message ); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
/**
|
||||
* General footer template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/general-footer.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
*
|
||||
* @version 1.5.4
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center" valign="top" class="footer">
|
||||
<?php
|
||||
/* translators: %s - link to the site. */
|
||||
printf( esc_html__( 'Sent from %s', 'wpforms-lite' ), '<a href="' . esc_url( home_url() ) . '">' . esc_html( wp_specialchars_decode( get_bloginfo( 'name' ) ) ) . '</a>' );
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
/**
|
||||
* General header template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/general-header.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
*
|
||||
* @version 1.5.4
|
||||
*
|
||||
* @var string $title
|
||||
* @var string $header_image
|
||||
*/
|
||||
|
||||
if ( ! \defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width">
|
||||
<title><?php echo \esc_html( $title ); ?></title>
|
||||
</head>
|
||||
<body>
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" height="100%" class="body">
|
||||
<tr>
|
||||
<td align="center" valign="top" class="body-inner">
|
||||
<table border="0" cellpadding="0" cellspacing="0" class="container">
|
||||
<tr>
|
||||
<td align="center" valign="middle" class="header">
|
||||
<?php if ( ! empty( $header_image['url'] ) ) : ?>
|
||||
<img src="<?php echo \esc_url( $header_image['url'] ); ?>" <?php echo isset( $header_image['width'] ) ? 'width="' . \absint( $header_image['width'] ) . '"' : ''; ?> alt="<?php echo \esc_attr( \get_bloginfo( 'name' ) ); ?>" />
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="left" valign="top" class="content">
|
||||
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
/**
|
||||
* General media queries style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/general-queries.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
*
|
||||
* @version 1.5.4
|
||||
*/
|
||||
|
||||
if ( ! \defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
require \WPFORMS_PLUGIN_DIR . 'assets/css/emails/partials/media_queries.css';
|
||||
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
/**
|
||||
* General style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/general-style.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
*
|
||||
* @version 1.5.4
|
||||
*
|
||||
* @var string $email_background_color
|
||||
*/
|
||||
|
||||
if ( ! \defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
require \WPFORMS_PLUGIN_DIR . '/assets/css/emails/general.min.css';
|
||||
|
||||
?>
|
||||
|
||||
body, .body {
|
||||
background-color: <?php echo \esc_attr( $email_background_color ); ?>;
|
||||
}
|
||||
|
||||
<?php if ( ! empty( $header_image_max_width ) ) : ?>
|
||||
.header img {
|
||||
max-width: <?php echo esc_attr( $header_image_max_width ); ?>px;
|
||||
}
|
||||
<?php endif; ?>
|
||||
@@ -0,0 +1,102 @@
|
||||
<?php
|
||||
/**
|
||||
* Email Summary body template (plain text).
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/summary-body-plain.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
* @since 1.8.8 Added `$overview`, and `$notification_block` parameters.
|
||||
*
|
||||
* @var array $overview Form entries overview data.
|
||||
* @var array $entries Form entries data to loop through.
|
||||
* @var array $notification_block Notification block shown before the Info block.
|
||||
* @var array $info_block Info block shown at the end of the email.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
// Used to separate strings in the email.
|
||||
$separator = ' | ';
|
||||
|
||||
echo esc_html__( 'Hi there!', 'wpforms-lite' ) . "\n\n";
|
||||
|
||||
echo esc_html__( 'Let’s see how your forms performed in the past week.', 'wpforms-lite' ) . "\n\n";
|
||||
|
||||
if ( ! wpforms()->is_pro() ) {
|
||||
echo esc_html__( 'Below is the total number of submissions for each form, however actual entries are not stored in WPForms Lite.', 'wpforms-lite' ) . "\n\n";
|
||||
echo esc_html__( 'To view future entries inside your WordPress dashboard, and get more detailed reports, consider upgrading to Pro:', 'wpforms-lite' );
|
||||
echo ' ';
|
||||
echo 'https://wpforms.com/lite-upgrade/?utm_source=WordPress&utm_medium=Weekly%20Summary%20Email&utm_campaign=liteplugin&utm_content=Upgrade&utm_locale=' . wpforms_sanitize_key( get_locale() );
|
||||
echo "\n\n\n";
|
||||
}
|
||||
|
||||
if ( isset( $overview['total'] ) ) {
|
||||
echo "=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n\n";
|
||||
printf( /* translators: %1$d - number of entries. */
|
||||
esc_html__( '%1$d Total', 'wpforms-lite' ),
|
||||
absint( $overview['total'] )
|
||||
);
|
||||
|
||||
if ( isset( $overview['trends'] ) ) {
|
||||
echo esc_html( $separator ) . ( (int) $overview['trends'] >= 0 ? '↑' : '↓' ) . esc_html( $overview['trends'] ) . "\n\n";
|
||||
echo wp_kses( _n( 'Entry This Week', 'Entries This Week', absint( $overview['total'] ), 'wpforms-lite' ), [] );
|
||||
}
|
||||
|
||||
echo "\n\n=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n\n";
|
||||
}
|
||||
|
||||
echo "=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n\n";
|
||||
|
||||
echo esc_html__( 'Form', 'wpforms-lite' ) . esc_html( $separator ) . esc_html__( 'Entries', 'wpforms-lite' );
|
||||
|
||||
echo "\n\n=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n\n";
|
||||
|
||||
foreach ( $entries as $row ) {
|
||||
echo ( isset( $row['title'] ) ? esc_html( $row['title'] ) : '' ) . esc_html( $separator ) . ( isset( $row['count'] ) ? absint( $row['count'] ) : '' );
|
||||
|
||||
if ( isset( $row['trends'] ) ) {
|
||||
echo esc_html( $separator ) . ( (int) $row['trends'] >= 0 ? '↑' : '↓' ) . esc_html( $row['trends'] );
|
||||
}
|
||||
|
||||
echo "\n\n";
|
||||
}
|
||||
|
||||
if ( empty( $entries ) ) {
|
||||
echo esc_html__( 'It appears you do not have any form entries yet.', 'wpforms-lite' ) . "\n\n";
|
||||
}
|
||||
|
||||
if ( ! empty( $notification_block ) ) {
|
||||
echo "=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n\n\n";
|
||||
|
||||
if ( ! empty( $notification_block['title'] ) ) {
|
||||
echo esc_html( $notification_block['title'] ) . "\n\n";
|
||||
}
|
||||
|
||||
if ( ! empty( $notification_block['content'] ) ) {
|
||||
echo wp_kses_post( $notification_block['content'] ) . "\n\n";
|
||||
}
|
||||
|
||||
if ( ! empty( $notification_block['btns']['main']['url'] ) && ! empty( $notification_block['btns']['main']['text'] ) ) {
|
||||
echo esc_html( $notification_block['btns']['main']['text'] ) . ': ' . esc_url( $notification_block['btns']['main']['url'] ) . "\n\n";
|
||||
}
|
||||
|
||||
if ( ! empty( $notification_block['btns']['alt']['url'] ) && ! empty( $notification_block['btns']['alt']['text'] ) ) {
|
||||
echo esc_html( $notification_block['btns']['alt']['text'] ) . ': ' . esc_url( $notification_block['btns']['alt']['url'] ) . "\n\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n\n\n";
|
||||
|
||||
if ( ! empty( $info_block['title'] ) ) {
|
||||
echo esc_html( $info_block['title'] ) . "\n\n";
|
||||
}
|
||||
|
||||
if ( ! empty( $info_block['content'] ) ) {
|
||||
echo wp_kses_post( $info_block['content'] ) . "\n\n";
|
||||
}
|
||||
|
||||
if ( ! empty( $info_block['button'] ) && ! empty( $info_block['url'] ) ) {
|
||||
echo esc_html( $info_block['button'] ) . ': ' . esc_url( $info_block['url'] ) . "\n\n";
|
||||
}
|
||||
@@ -0,0 +1,318 @@
|
||||
<?php
|
||||
/**
|
||||
* Email Summary body template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/summary-body.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
* @since 1.8.8 Added `$overview`, `$has_trends`, `$notification_block`, and `$icons` parameters.
|
||||
*
|
||||
* @var array $overview Form entries overview data.
|
||||
* @var array $entries Form entries data to loop through.
|
||||
* @var bool $has_trends Whether trends data is available.
|
||||
* @var array $notification_block Notification block shown before the Info block.
|
||||
* @var array $info_block Info block shown at the end of the email.
|
||||
* @var array $icons Icons used for the design purposes.
|
||||
*/
|
||||
|
||||
use WPForms\Integrations\LiteConnect\LiteConnect;
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<table class="summary-container" border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="summary-content" bgcolor="#ffffff">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
<td class="summary-content-inner" align="center" valign="top" width="600">
|
||||
<div class="summary-header" width="100%">
|
||||
<h6 class="greeting"><?php esc_html_e( 'Hi there!', 'wpforms-lite' ); ?></h6>
|
||||
<p><?php esc_html_e( 'Let’s see how your forms performed in the past week.', 'wpforms-lite' ); ?></p>
|
||||
<?php if ( ! wpforms()->is_pro() ) : ?>
|
||||
<p class="lite-disclaimer">
|
||||
<?php esc_html_e( 'Below is the total number of submissions for each form. However, form entries are not stored by WPForms Lite.', 'wpforms-lite' ); ?>
|
||||
</p>
|
||||
|
||||
<?php if ( LiteConnect::is_enabled() ) : ?>
|
||||
<p class="lite-disclaimer">
|
||||
<strong><?php esc_html_e( 'We’ve got you covered!', 'wpforms-lite' ); ?></strong><br/>
|
||||
<?php
|
||||
printf(
|
||||
wp_kses( /* translators: %1$s - WPForms.com Upgrade page URL. */
|
||||
__( 'Your entries are being backed up securely in the cloud. When you’re ready to manage your entries inside WordPress, just <a href="%1$s" target="_blank" rel="noopener noreferrer">upgrade to Pro</a> and we’ll automatically import them in seconds!', 'wpforms-lite' ),
|
||||
[
|
||||
'a' => [
|
||||
'href' => [],
|
||||
'rel' => [],
|
||||
'target' => [],
|
||||
],
|
||||
]
|
||||
),
|
||||
esc_url( wpforms_utm_link( 'https://wpforms.com/lite-upgrade/', 'Weekly Summary Email', 'Upgrade' ) )
|
||||
);
|
||||
?>
|
||||
</p>
|
||||
<p class="lite-disclaimer">
|
||||
<?php
|
||||
printf(
|
||||
'<a href="%1$s" target="_blank" rel="noopener noreferrer"><strong>%2$s</strong></a>',
|
||||
esc_url( wpforms_utm_link( 'https://wpforms.com/lite-upgrade/', 'Weekly Summary Email', 'Upgrade' ) ),
|
||||
esc_html__( 'Check out what else you’ll get with your Pro license.', 'wpforms-lite' )
|
||||
);
|
||||
?>
|
||||
</p>
|
||||
<?php else : ?>
|
||||
<p class="lite-disclaimer">
|
||||
<strong><?php esc_html_e( 'Note: Entry backups are not enabled.', 'wpforms-lite' ); ?></strong><br/>
|
||||
<?php esc_html_e( 'We recommend that you enable entry backups to guard against lost entries.', 'wpforms-lite' ); ?>
|
||||
</p>
|
||||
<p class="lite-disclaimer">
|
||||
<?php
|
||||
printf(
|
||||
wp_kses( /* translators: %1$s - WPForms.com Documentation page URL. */
|
||||
__( 'Backups are completely free, 100%% secure, and you can turn them on in a few clicks! <a href="%1$s" target="_blank" rel="noopener noreferrer">Enable entry backups now.</a>', 'wpforms-lite' ),
|
||||
[
|
||||
'a' => [
|
||||
'href' => [],
|
||||
'rel' => [],
|
||||
'target' => [],
|
||||
],
|
||||
]
|
||||
),
|
||||
esc_url( wpforms_utm_link( 'https://wpforms.com/docs/how-to-use-lite-connect-for-wpforms/', 'Weekly Summary Email', 'Documentation#backup-with-lite-connect' ) )
|
||||
);
|
||||
?>
|
||||
</p>
|
||||
<p class="lite-disclaimer">
|
||||
<?php
|
||||
printf(
|
||||
wp_kses( /* translators: %1$s - WPForms.com Upgrade page URL. */
|
||||
__( 'When you’re ready to manage your entries inside WordPress, <a href="%1$s" target="_blank" rel="noopener noreferrer">upgrade to Pro</a> to import your entries.', 'wpforms-lite' ),
|
||||
[
|
||||
'a' => [
|
||||
'href' => [],
|
||||
'rel' => [],
|
||||
'target' => [],
|
||||
],
|
||||
]
|
||||
),
|
||||
esc_url( wpforms_utm_link( 'https://wpforms.com/lite-upgrade/', 'Weekly Summary Email', 'Upgrade' ) )
|
||||
);
|
||||
?>
|
||||
</p>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<div class="email-summaries-overview-wrapper" width="100%">
|
||||
<?php if ( isset( $overview['total'] ) ) : ?>
|
||||
<table class="email-summaries-overview" border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation" bgcolor="#f8f8f8">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="overview-icon" valign="top">
|
||||
<img src="<?php echo esc_url( $icons['overview'] ); ?>" width="52" height="52" alt="<?php esc_attr_e( 'Overview', 'wpforms-lite' ); ?>" />
|
||||
</td>
|
||||
<td class="overview-stats" valign="top">
|
||||
<h5>
|
||||
<?php
|
||||
printf(
|
||||
/* translators: %1$d - number of entries. */
|
||||
esc_html__( '%1$d Total', 'wpforms-lite' ),
|
||||
absint( $overview['total'] )
|
||||
);
|
||||
?>
|
||||
</h5>
|
||||
<p>
|
||||
<?php echo wp_kses( _n( 'Entry This Week', 'Entries This Week', absint( $overview['total'] ), 'wpforms-lite' ), [] ); ?>
|
||||
</p>
|
||||
</td>
|
||||
<?php if ( isset( $overview['trends'] ) ) : ?>
|
||||
<td class="summary-trend">
|
||||
<table class="trend-<?php echo esc_attr( (int) $overview['trends'] < 0 ? 'downward' : 'upward' ); ?>" border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tr valign="middle">
|
||||
<td valign="middle">
|
||||
<img src="<?php echo esc_url( $icons[ (int) $overview['trends'] < 0 ? 'downward' : 'upward' ] ); ?>" width="14" height="18" alt="<?php echo esc_attr( (int) $overview['trends'] < 0 ? 'downward' : 'upward' ); ?>" />
|
||||
</td>
|
||||
<td dir="ltr" valign="middle">
|
||||
<?php echo esc_html( $overview['trends'] ); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<?php endif; ?>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<div class="email-summaries-wrapper" width="100%">
|
||||
<table class="email-summaries" border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<thead>
|
||||
<tr>
|
||||
<th align="<?php echo is_rtl() ? 'right' : 'left'; ?>" valign="top"><?php esc_html_e( 'Form', 'wpforms-lite' ); ?></th>
|
||||
<th class="entries-column" align="<?php echo is_rtl() ? 'right' : 'left'; ?>" valign="top" colspan="2"><?php esc_html_e( 'Entries', 'wpforms-lite' ); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ( $entries as $row ) : ?>
|
||||
<tr id="form-<?php echo esc_attr( $row['form_id'] ); ?>">
|
||||
<td class="form-name" valign="middle"><?php echo isset( $row['title'] ) ? esc_html( $row['title'] ) : ''; ?></td>
|
||||
<td class="entry-count" align="center" valign="middle">
|
||||
<?php if ( empty( $row['edit_url'] ) ) : ?>
|
||||
<span>
|
||||
<?php echo isset( $row['count'] ) ? absint( $row['count'] ) : ''; ?>
|
||||
</span>
|
||||
<?php else : ?>
|
||||
<a href="<?php echo esc_url( $row['edit_url'] ); ?>">
|
||||
<?php echo isset( $row['count'] ) ? absint( $row['count'] ) : ''; ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<?php if ( $has_trends ) : ?>
|
||||
<td class="summary-trend" align="center" valign="middle">
|
||||
<?php if ( isset( $row['trends'] ) ) : ?>
|
||||
<table class="trend-<?php echo esc_attr( (int) $row['trends'] < 0 ? 'downward' : 'upward' ); ?>" border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tr valign="middle">
|
||||
<td valign="middle">
|
||||
<img src="<?php echo esc_url( $icons[ (int) $row['trends'] < 0 ? 'downward' : 'upward' ] ); ?>" width="10" height="13" alt="<?php echo esc_attr( (int) $row['trends'] < 0 ? 'downward' : 'upward' ); ?>" />
|
||||
</td>
|
||||
<td dir="ltr" valign="middle">
|
||||
<?php echo esc_html( $row['trends'] ); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<?php else : ?>
|
||||
—
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<?php endif; ?>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
|
||||
<?php if ( empty( $entries ) ) : ?>
|
||||
<tr>
|
||||
<td colspan="3">
|
||||
<?php esc_html_e( 'It appears you do not have any form entries yet.', 'wpforms-lite' ); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</td>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<?php if ( ! empty( $notification_block ) ) : ?>
|
||||
<tr class="summary-notice" align="center">
|
||||
<td class="summary-notification-block" bgcolor="#edf3f7">
|
||||
<table class="summary-notification-table summary-notification-table" border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tbody>
|
||||
<?php if ( ! empty( $icons['notification_block'] ) ) : ?>
|
||||
<tr>
|
||||
<td class="summary-notice-icon" align="center" valign="middle">
|
||||
<img src="<?php echo esc_url( $icons['notification_block'] ); ?>" width="52" height="52" alt="<?php esc_attr_e( 'Notification', 'wpforms-lite' ); ?>" />
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $notification_block['title'] ) || ! empty( $notification_block['content'] ) ) : ?>
|
||||
<tr>
|
||||
<td class="summary-notice-content" align="center" valign="middle">
|
||||
<?php if ( ! empty( $notification_block['title'] ) ) : ?>
|
||||
<h4><?php echo esc_html( $notification_block['title'] ); ?></h4>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $notification_block['content'] ) ) : ?>
|
||||
<p><?php echo wp_kses_post( $notification_block['content'] ); ?></p>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( ! empty( $notification_block['btns'] ) ) : ?>
|
||||
<tr>
|
||||
<td class="button-container" align="center" valign="middle">
|
||||
<table class="button-wrapper" cellspacing="24">
|
||||
<tr>
|
||||
<?php if ( ! empty( $notification_block['btns']['main']['url'] ) && ! empty( $notification_block['btns']['main']['text'] ) ) : ?>
|
||||
<td class="button button-blue" align="center" border="1" valign="middle">
|
||||
<a href="<?php echo esc_url( $notification_block['btns']['main']['url'] ); ?>" class="button-link" rel="noopener noreferrer" target="_blank" bgcolor="#036aab">
|
||||
<?php echo esc_html( $notification_block['btns']['main']['text'] ); ?>
|
||||
</a>
|
||||
</td>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $notification_block['btns']['alt']['url'] ) && ! empty( $notification_block['btns']['alt']['text'] ) ) : ?>
|
||||
<td class="button button-blue-outline" align="center" border="1" valign="middle">
|
||||
<a href="<?php echo esc_url( $notification_block['btns']['alt']['url'] ); ?>" class="button-link" rel="noopener noreferrer" target="_blank" bgcolor="#edf3f7">
|
||||
<?php echo esc_html( $notification_block['btns']['alt']['text'] ); ?>
|
||||
</a>
|
||||
</td>
|
||||
<?php endif; ?>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $info_block ) ) : ?>
|
||||
<?php if ( ! empty( $notification_block ) ) : ?>
|
||||
<tr><td class="summary-notice-divider" height="1"> </td></tr>
|
||||
<?php endif; ?>
|
||||
<tr class="summary-notice" align="center">
|
||||
<td class="summary-info-block" bgcolor="#f7f0ed">
|
||||
<table class="summary-info-table summary-notice-table" border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tbody>
|
||||
<?php if ( ! empty( $icons['info_block'] ) ) : ?>
|
||||
<tr>
|
||||
<td class="summary-notice-icon" align="center" valign="middle">
|
||||
<img src="<?php echo esc_url( $icons['info_block'] ); ?>" width="52" height="52" alt="<?php esc_attr_e( 'Info', 'wpforms-lite' ); ?>" />
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $info_block['title'] ) || ! empty( $info_block['content'] ) ) : ?>
|
||||
<tr>
|
||||
<td class="summary-notice-content" align="center" valign="middle">
|
||||
<?php if ( ! empty( $info_block['title'] ) ) : ?>
|
||||
<h4><?php echo esc_html( $info_block['title'] ); ?></h4>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $info_block['content'] ) ) : ?>
|
||||
<p><?php echo wp_kses_post( $info_block['content'] ); ?></p>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( ! empty( $info_block['url'] ) && ! empty( $info_block['button'] ) ) : ?>
|
||||
<tr>
|
||||
<td class="button-container" align="center" valign="middle">
|
||||
<table class="button-wrapper" cellspacing="24">
|
||||
<tr>
|
||||
<td class="button button-orange" align="center" border="1" valign="middle">
|
||||
<a href="<?php echo esc_url( $info_block['url'] ); ?>" class="button-link" rel="noopener noreferrer" target="_blank" bgcolor="#e27730">
|
||||
<?php echo esc_html( $info_block['button'] ); ?>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
/**
|
||||
* Summary footer template (plain text).
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/summary-footer-plain.php.
|
||||
*
|
||||
* @since 1.6.2.3
|
||||
*
|
||||
* @version 1.6.2.3
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
echo "\n---\n\n";
|
||||
printf( /* translators: %s - link to the site. */
|
||||
esc_html__( 'This email was auto-generated and sent from %s.', 'wpforms-lite' ),
|
||||
esc_html( wp_specialchars_decode( get_bloginfo( 'name' ) ) )
|
||||
);
|
||||
echo "\n";
|
||||
printf( /* translators: %s - link to the documentation. */
|
||||
esc_html__( 'Learn how to disable: %s.', 'wpforms-lite' ),
|
||||
'https://wpforms.com/docs/how-to-use-email-summaries/#disable-email-summaries'
|
||||
);
|
||||
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
/**
|
||||
* Summary footer template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/summary-footer.php.
|
||||
*
|
||||
* @since 1.6.2.3
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="<?php echo is_rtl() ? 'right' : 'left'; ?>" valign="top" class="footer">
|
||||
<?php
|
||||
printf(
|
||||
wp_kses( /* translators: %1$s - site URL, %2$s - link to the documentation. */
|
||||
__( 'This email was auto-generated and sent from %1$s. Learn <a href="%2$s">how to disable</a>', 'wpforms-lite' ),
|
||||
[
|
||||
'a' => [
|
||||
'href' => [],
|
||||
],
|
||||
]
|
||||
),
|
||||
'<a href="' . esc_url( home_url() ) . '">' . esc_html( wp_specialchars_decode( get_bloginfo( 'name' ) ) ) . '</a>',
|
||||
'https://wpforms.com/docs/how-to-use-email-summaries/#disable-email-summaries'
|
||||
);
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</td>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
/**
|
||||
* Summary header template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/summary-header.php.
|
||||
*
|
||||
* @since 1.8.8
|
||||
*
|
||||
* @var string $title Email title.
|
||||
* @var array $header_image Header image arguments.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit; // Exit if accessed directly.
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html <?php language_attributes(); ?>>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=<?php bloginfo( 'charset' ); ?>">
|
||||
<meta content="width=device-width, initial-scale=1.0" name="viewport">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="color-scheme" content="light dark">
|
||||
<title><?php echo esc_html( $title ); ?></title>
|
||||
</head>
|
||||
<body <?php echo is_rtl() ? 'rightmargin' : 'leftmargin'; ?>="0" marginwidth="0" topmargin="0" marginheight="0" offset="0" bgcolor="#f8f8f8" class="<?php echo is_rtl() ? 'rtl' : 'ltr'; ?>">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" height="100%" class="body" role="presentation" bgcolor="#f8f8f8">
|
||||
<tr>
|
||||
<td><!-- Deliberately empty to support consistent sizing and layout across multiple email clients. --></td>
|
||||
<td align="center" valign="top" class="body-inner" width="700">
|
||||
<div class="wrapper" width="100%" dir="<?php echo is_rtl() ? 'rtl' : 'ltr'; ?>">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" class="container" role="presentation">
|
||||
<?php if ( ! empty( $header_image['url_dark'] ) ) : ?>
|
||||
<tr class="header-wrapper dark-mode">
|
||||
<td align="center" valign="middle" class="header">
|
||||
<div class="header-image">
|
||||
<img width="260" src="<?php echo esc_url( $header_image['url_dark'] ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php if ( ! empty( $header_image['url_light'] ) ) : ?>
|
||||
<tr class="header-wrapper light-mode">
|
||||
<td align="center" valign="middle" class="header">
|
||||
<div class="header-image">
|
||||
<img width="260" src="<?php echo esc_url( $header_image['url_light'] ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<tr>
|
||||
<td class="wrapper-inner">
|
||||
<table border="0" cellpadding="0" cellspacing="0" width="100%" role="presentation">
|
||||
<tr>
|
||||
<td valign="top" class="content">
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
/**
|
||||
* Summary media queries style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/summary-queries.php.
|
||||
*
|
||||
* Note: To override the existing styles of the template in this file, ensure that all
|
||||
* overriding styles are declared as !important to take precedence over the default styles.
|
||||
*
|
||||
* @since 1.8.8
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
require WPFORMS_PLUGIN_DIR . 'assets/css/emails/partials/summary_media_queries.css';
|
||||
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
/**
|
||||
* Email Summary style template.
|
||||
*
|
||||
* This template can be overridden by copying it to yourtheme/wpforms/emails/summary-style.php.
|
||||
*
|
||||
* @since 1.5.4
|
||||
* @since 1.8.8 Removed `$header_image_max_width` parameter.
|
||||
*
|
||||
* @var string $email_background_color Background color for the email.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
require WPFORMS_PLUGIN_DIR . '/assets/css/emails/summary.min.css';
|
||||
|
||||
if ( ! empty( $email_background_color ) ) : ?>
|
||||
body, .body {
|
||||
background-color: <?php echo sanitize_hex_color( $email_background_color ); ?> !important;
|
||||
}
|
||||
<?php endif; ?>
|
||||
Reference in New Issue
Block a user