Opened 14 years ago
Closed 11 years ago
#14893 closed defect (bug) (worksforme)
wp_inactive_widgets sidebar forgotten, then does notice in /wp-admin/widgets.php
Reported by: | hakre | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 3.0.1 |
Component: | Warnings/Notices | Keywords: | has-patch |
Focuses: | Cc: |
Description
The 'wp_inactive_widgets' is not initalized but used later on.
Can be fixed easily by adding it while the array get's initialized.
Attachments (1)
Change History (11)
#1
@
14 years ago
- Summary changed from wp_inactive_widgets sidebar forgotten, than does notice in /wp-admin/widgets.php to wp_inactive_widgets sidebar forgotten, then does notice in /wp-admin/widgets.php
#3
in reply to:
↑ 2
@
14 years ago
Replying to Denis-de-Bernardy:
Mm, I'm suspecting the suggested patch will break some upgrade/backwards compatibility code we introduced around WP 2.8. It's better use isset() where needed to avoid the notices when there are any.
Can you please make that suspection concrete with the patch because I do not see the problem here.
#5
@
13 years ago
Tons more here, for your reading pleasure: #9511. don't forget to look around in related tickets, and related to related tickets.
Alternatively, trust me a take this short short version at face value: the WP widgets API will blow up in your face on changes like the one you suggest, and it's better to add whatever isset() calls are needed until it's rewritten from the ground up.
#6
@
13 years ago
- Milestone changed from Awaiting Review to Future Release
How many places would isset()
checks be required to squash the notices? If it's just a handful, do that.
#7
follow-up:
↓ 8
@
11 years ago
have the same issue, the problem is that the notice appears only once ( after theme actiavation ) :
wp_inactive_widgets in D:\Dropbox\htdocs\wordpresslastmu\wp-includes\widgets.php on line 1266
#9
in reply to:
↑ 8
@
11 years ago
Replying to SergeyBiryukov:
The code was changed in #17979. Could you please add the steps to reproduce? Does it happen with a specific theme?
everything is fine now, I made some modifications and the sidebars[wp_inactive_widgets]
javascript value from widgets.php page were missing in the widgets data array (js)
Mm, I'm suspecting the suggested patch will break some upgrade/backwards compatibility code we introduced around WP 2.8. It's better use isset() where needed to avoid the notices when there are any.