elementor / elementor/elementor
Elementor prints the front page of our website on receipts that used Smart Coupons
- Dominant language
- PHP
- Stars
- 7.1k
- Forks
- 1.6k
- Avg merge
- 1d 5h
- Merged PRs (30d)
- 193
Description
## Prerequisites
- [X ] I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
- [ ] The issue still exists against the latest stable version of Elementor.
## Description
As requested by the Elementor support desk, we are posting this issue here...
Elementor hijacks the emailed store receipt and prints the ENTIRE FRONT PAGE of our website on it when someone uses a coupon.
Issue does NOT occur if Elementor is disabled.
## Steps to reproduce
Install the WooCommerce Smart Coupons Plugin by StoreApps v4.0.8, v4.5, v4.7, etc.
Install Elementor or Elementor and Elementor Pro
Make the front page of the website an Elementor page
Create a coupon
Select that a coupon message be added to the emailed receipt and write a coupon message into the text box
Use the coupon
Look at the emailed receipt (Both store copy and customer copy)
## Isolating the problem
- [ ] This bug happens with only Elementor plugin active (and Elementor Pro).
- [ ] This bug happens with a default WordPress theme active.
- [X] I can reproduce this bug consistently using the steps above.
To verify and test this issue we made a clean subdomain install installing only WooCommerce, Elementor and Smart Coupons. 100% repeatable.
The Smart Coupon developers looked into it and found this to be the code you are hijacking:
_Thank you for sharing the steps to replicate the issue. I was able to replicate the issue on my machine.
I've rechecked the code of the Smart Coupons plugin & found that there's only one code which is there add the coupon message in the email, which I suppose that the Elementor plugin is overriding.
The code is:
**apply_filters( 'the_content', $coupon_message )**
Can you please share this code with the Elementor developer team & ask how the Elementor plugin can affect this code. Also, share with them that instead of printing the content of the variable $coupon_message, it's printing the content of the home page created by the Elementor plugin._
## Environment
**This report is from one of our test sites, but the issue also occurred on our live site, where it was first noticed, and on our staging site as well. We setup this site just to test this issue in a clean environment.
ALSO, this test site wasn't setup using the latest versions of everything but the staging site is. We wanted to see if the issue was present in older versions as well as newer versions, it is. So please don't just respond with a suggestion to update to the latest versions as we've done that already and the problem persists.**
### WordPress Environment ###
WordPress address (URL): aaaaaaaaaaaaaaaaaaaaaa
Site address (URL): aaaaaaaaaaaaaaaaaaaaaaa
WC Version: 3.9.2
REST API Version: ✔ 1.0.7
Log Directory Writable: ✔
WP Version: 5.3.2
WP Multisite: –
WP Memory Limit: 256 MB
WP Debug Mode: –
WP Cron: ✔
Language: en_US
External object cache: –
### Server Environment ###
Server Info: Apache
PHP Version: 7.3.11
PHP Post Max Size: 65 MB
PHP Time Limit: 30
PHP Max Input Vars: 1000
cURL Version: 7.35.0
OpenSSL/1.0.1f
SUHOSIN Installed: –
MySQL Version: 5.7.28-log
Max Upload Size: 64 MB
Default Timezone is UTC: ✔
fsockopen/cURL: ✔
SoapClient: ✔
DOMDocument: ✔
GZip: ✔
Multibyte String: ✔
Remote Post: ✔
Remote Get: ✔
### Database ###
WC Database Version: 3.9.2
WC Database Prefix: wp_esctjp_
Total Database Size: 4.11MB
Database Data Size: 2.88MB
Database Index Size: 1.23MB
wp_esctjp_woocommerce_sessions: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_woocommerce_api_keys: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_woocommerce_attribute_taxonomies: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_woocommerce_downloadable_product_permissions: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
wp_esctjp_woocommerce_order_items: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_woocommerce_order_itemmeta: Data: 0.05MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_woocommerce_tax_rates: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
wp_esctjp_woocommerce_tax_rate_locations: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_woocommerce_shipping_zones: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
wp_esctjp_woocommerce_shipping_zone_locations: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_woocommerce_shipping_zone_methods: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
wp_esctjp_woocommerce_payment_tokens: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_woocommerce_payment_tokenmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_woocommerce_log: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_commentmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_comments: Data: 0.02MB + Index: 0.09MB + Engine InnoDB
wp_esctjp_links: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_options: Data: 2.05MB + Index: 0.06MB + Engine InnoDB
wp_esctjp_postmeta: Data: 0.05MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_posts: Data: 0.05MB + Index: 0.06MB + Engine InnoDB
wp_esctjp_termmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_terms: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_term_relationships: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_term_taxonomy: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_usermeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_users: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
wp_esctjp_wc_admin_notes: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
wp_esctjp_wc_admin_note_actions: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_wc_category_lookup: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
wp_esctjp_wc_customer_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_wc_download_log: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_wc_order_coupon_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_wc_order_product_lookup: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
wp_esctjp_wc_order_stats: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
wp_esctjp_wc_order_tax_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
wp_esctjp_wc_product_meta_lookup: Data: 0.02MB + Index: 0.09MB + Engine InnoDB
wp_esctjp_wc_tax_rate_classes: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
wp_esctjp_wc_webhooks: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
### Post Type Counts ###
attachment: 2
elementor_library: 1
page: 8
post: 3
product: 1
revision: 5
scheduled-action: 9
shop_coupon: 1
shop_order: 4
### Security ###
Secure connection (HTTPS): ❌
Your store is not using HTTPS. Learn more about HTTPS and SSL Certificates.
Hide errors from visitors: ✔
### Active Plugins (10) ###
DreamHost Panel Login: by DreamHost
danielbachhuber – 1.0.0
Elementor: by Elementor.com – 2.9.2
Jetpack by WordPress.com: by Automattic – 8.2.3
UpdraftPlus - Backup/Restore: by UpdraftPlus.Com
DavidAnderson – 1.16.22
WooCommerce Admin: by WooCommerce – 0.26.1
WooCommerce Services: by Automattic – 1.22.3 – 1.22.4 is available
WooCommerce Smart Coupons: by StoreApps – 4.0.8 – Not tested with the active version of WooCommerce
WooCommerce: by Automattic – 3.9.2 – 3.9.3 is available
WP Super Cache: by Automattic – 1.7.1
WPForms Lite: by WPForms – 1.5.8.2
### Inactive Plugins (4) ###
Akismet Anti-Spam: by Automattic – 4.1.3
Google Analytics for WordPress by MonsterInsights: by MonsterInsights – 7.10.4
Hello Dolly: by Matt Mullenweg – 1.7.2
OptinMonster API: by OptinMonster Team – 1.9.6 – Not tested with the active version of WooCommerce
### Dropin Plugins (1) ###
advanced-cache.php: advanced-cache.php
### Settings ###
API Enabled: –
Force SSL: –
Currency: USD ($)
Currency Position: left
Thousand Separator: ,
Decimal Separator: .
Number of Decimals: 2
Taxonomies: Product Types: external (external)
grouped (grouped)
simple (simple)
variable (variable)
Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog)
exclude-from-search (exclude-from-search)
featured (featured)
outofstock (outofstock)
rated-1 (rated-1)
rated-2 (rated-2)
rated-3 (rated-3)
rated-4 (rated-4)
rated-5 (rated-5)
Connected to WooCommerce.com: –
### WC Pages ###
Shop base: #6 - /shop/
Cart: #7 - /cart/
Checkout: #8 - /checkout/
My account: #9 - /my-account/
Terms and conditions: ❌ Page not set
### Theme ###
Name: Storefront
Version: 2.5.4 – 2.5.5 is available
Author URL: https://woocommerce.com/
Child Theme: ❌ – If you are modifying WooCommerce on a parent theme that you did not build personally we recommend using a child theme. See: How to create a child theme
WooCommerce Support: ✔
### Templates ###
Overrides: –
### Action Scheduler ###
Complete: 9
Oldest: 2020-02-25 22:24:39 +0000
Newest: 2020-02-28 16:18:19 +0000
Pending: 0
Oldest: –
Newest: –
Canceled: 0
Oldest: –
Newest: –
In-progress: 0
Oldest: –
Newest: –
Failed: 0
Oldest: –
Newest: –
`
```
```
Contributor guide
Assessment
This issue has not been assessed yet.