elementor / elementor/elementor
Custom Code Save & Close 403 Error
- 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.
- [x] The issue still exists against the latest stable version of Elementor.
## Description
Screen recording of steps and Console error [https://youtu.be/dLKBEeEbgCc](https://youtu.be/dLKBEeEbgCc)
Attempting to Save & Close Custom Code results in 403 Error. Console messages below:
```
common.min.js?ver=3.2.4:2 PUT https://www.lautrecotecabfranc.com/wp-json/elementor/v1/site-editor/templates-conditions/3261 403
{message: "", code: "", data: Array(0)}
Uncaught (in promise)
Response {type: "basic", url: "https://www.lautrecotecabfranc.com/wp-json/elementor/v1/site-editor/templates-conditions/3261", redirected: false, status: 403, ok: false, …}
```
## Steps to reproduce
1. Navigate to Elementor > Custom Code
2. Click Add New Custom Code
3. Name the Custom Code, add in code. Click Publish.
4. At the Publish Settings, add condition Entire Site, click Save & Close.
5. Won't save & close, 403 error appears in the Inspector Console.
_* - Problem can be replicated with Safari also._
## Isolating the problem
- [x] This bug happens with only Elementor plugin active (and Elementor Pro).
- [x] This bug happens with a default WordPress theme active.
- [x] I can reproduce this bug consistently using the steps above.
## Environment
System Info
```
== Server Environment ==
Operating System: Linux
Software: LiteSpeed
MySQL version: MariaDB Server v10.3.23
PHP Version: 7.4.20
PHP Max Input Vars: 10000
PHP Max Post Size: 512M
GD Installed: Yes
ZIP Installed: Yes
Write Permissions: All right
Elementor Library: Connected
== WordPress Environment ==
Version: 5.7.2
Site URL: https://www.lautrecotecabfranc.com
Home URL: https://www.lautrecotecabfranc.com
WP Multisite: No
Max Upload Size: 512 MB
Memory limit: 1G
Permalink Structure: /%postname%/
Language: en-US
Timezone: America/Los_Angeles
Debug Mode: Inactive
== Theme ==
Name: L'autre Côte
Version: 1.0
Author: Leonel Calara
Child Theme: Yes
Parent Theme Name: Hello Elementor
Parent Theme Version: 2.3.1
Parent Theme Author: Elementor Team
== User ==
Role: administrator
WP Profile lang: en_US
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.101 Safari/537.36
== Active Plugins ==
All In One WP Security
Version: 4.4.8
Author: Tips and Tricks HQ, Peter Petreski, Ruhul, Ivy
Cloudflare
Version: 4.5.1
Author: Cloudflare, Inc.
Defender
Version: 2.5.3
Author: WPMU DEV
Duplicate Page
Version: 4.4
Author: mndpsingh287
Elementor
Version: 3.2.4
Author: Elementor.com
Elementor Addon Elements
Version: 1.11.5
Author: WPVibes
Elementor Pro
Version: 3.3.0
Author: Elementor.com
Erident Custom Login and Dashboard
Version: 3.5.9
Author: Libin V Babu
Google Analytics for WordPress by MonsterInsights
Version: 7.17.0
Author: MonsterInsights
Head, Footer and Post Injections
Version: 3.2.2
Author: Stefano Lissa
Hotjar
Version: 1.0.10
Author: Hotjar
Simple Page Ordering
Version: 2.3.4
Author: Jake Goldman, 10up
SVG Support
Version: 2.3.18
Author: Benbodhi
TablePress
Version: 1.13
Author: Tobias Bäthge
WP-Sweep
Version: 1.1.3
Author: Lester 'GaMerZ' Chan
WP Server Stats
Version: 1.6.10
Author: Saumya Majumder, Acnam Infotech
Yoast SEO
Version: 16.5
Author: Team Yoast
== Elementor - Compatibility Tag ==
Elementor Addon Elements: Incompatible
Elementor Pro: Compatible
== Elementor Pro - Compatibility Tag ==
Elementor Addon Elements: Incompatible
== Elements Usage ==
footer : 2
button : 3
divider : 5
heading : 17
image : 12
social-icons : 2
header : 5
button : 3
heading : 1
icon : 3
image : 3
nav-menu : 5
search-form : 6
spacer : 3
theme-site-logo : 3
popup : 2
button : 1
text-editor : 1
video : 1
section : 3
heading : 1
html : 1
nav-menu : 2
text-editor : 1
wp-page : 8
button : 7
divider : 4
form : 2
heading : 26
html : 2
icon : 1
image : 4
spacer : 2
text-editor : 30
== Log ==
Log: showing 20 of 402021-04-22 06:50:28 [info] Elementor data updater process has been completed. [array (
'plugin' => 'Elementor',
'from' => '3.1.4',
'to' => '3.2.1',
)]
2021-05-01 06:50:24 [info] Elementor data updater process has been completed. [array (
'plugin' => 'Elementor',
'from' => '3.2.1',
'to' => '3.2.2',
)]
2021-05-09 22:26:22 [info] Elementor data updater process has been completed. [array (
'plugin' => 'Elementor',
'from' => '3.2.2',
'to' => '3.2.3',
)]
2021-05-09 22:26:22 [info] Elementor data updater process has been completed. [array (
'plugin' => 'Elementor Pro',
'from' => '3.2.1',
'to' => '3.2.2',
)]
2021-05-29 08:17:25 [info] Elementor data updater process has been completed. [array (
'plugin' => 'Elementor',
'from' => '3.2.3',
'to' => '3.2.4',
)]
2021-06-09 13:11:15 [info] elementor-pro::elementor_pro_updater Started
2021-06-09 13:11:15 [info] Elementor Pro/Upgrades - _v_3_3_0_nav_menu_icon Start
2021-06-09 13:11:15 [info] Elementor data updater process has been queued. [array (
'plugin' => 'Elementor Pro',
'from' => '3.2.2',
'to' => '3.3.0',
)]
2021-06-09 13:11:15 [info] Elementor Pro/Upgrades - _v_3_3_0_nav_menu_icon callback needs to run more 3 times
2021-06-09 13:11:16 [info] elementor-pro::elementor_pro_updater Started
2021-06-09 13:11:16 [info] Elementor Pro/Upgrades - _v_3_3_0_nav_menu_icon Start (2 of 4, 50%)
2021-06-09 13:11:17 [info] elementor-pro::elementor_pro_updater Started
2021-06-09 13:11:17 [info] Elementor Pro/Upgrades - _v_3_3_0_nav_menu_icon Start (3 of 4, 75%)
2021-06-09 13:11:18 [info] elementor-pro::elementor_pro_updater Started
2021-06-09 13:11:18 [info] Elementor Pro/Upgrades - _v_3_3_0_nav_menu_icon Start (4 of 4, 100%)
2021-06-09 13:11:19 [info] Elementor Pro/Upgrades - _v_3_3_0_nav_menu_icon Finished
2021-06-09 13:11:20 [info] elementor-pro::elementor_pro_updater Started
2021-06-09 13:11:20 [info] Elementor Pro/Upgrades - _v_3_3_0_recalc_usage_data Start
2021-06-09 13:11:20 [info] Elementor Pro/Upgrades - _v_3_3_0_recalc_usage_data Finished
2021-06-09 13:11:20 [info] Elementor data updater process has been completed. [array (
'plugin' => 'Elementor Pro',
'from' => '3.2.2',
'to' => '3.3.0',
)]
PHP: showing 2 of 2PHP: 2021-04-04 02:41:23 [notice X 10][/home/nelcalara/lautrecotecabfranc.com/wp-content/plugins/elementor/modules/system-info/reporters/user.php::113] Undefined index: HTTP_USER_AGENT [array (
'trace' => '
#0: Elementor\Core\Logger\Manager -> shutdown()
',
)]
PHP: 2021-05-10 16:39:11 [notice X 11][/home/nelcalara/lautrecotecabfranc.com/wp-content/plugins/elementor/includes/conditions.php::90] Trying to access array offset on value of type null [array (
'trace' => '
#0: Elementor\Core\Logger\Manager -> shutdown()
',
)]
```
Contributor guide
Assessment
This issue has not been assessed yet.