Opened 15 years ago
Closed 12 years ago
#11969 closed defect (bug) (fixed)
Theme-Editor - Relocates to a URL containing full path after a change is saved.
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 3.4 | Priority: | low |
Severity: | normal | Version: | 2.9.2 |
Component: | Administration | Keywords: | has-patch |
Focuses: | Cc: |
Description
Hello,
First time reporting a bug, I didn't find this when searching...
When I am using the theme editor I am returned to a different URL after clicking the "Update File" button, which requires me to use my browser's back button to return to the theme editor. All my plugins have been disabled and this first started happening after upgrading to 2.9.1
when editing a theme file my url is:
http://www.mysite.com/wp-admin/theme-editor.php?file=/themes/mytheme/sidebar.php
after clicking the update file button it sends me here:
Attachments (2)
Change History (14)
#3
@
15 years ago
- Keywords needs-patch added
- Owner set to matdumsa
- Priority changed from normal to low
- Status changed from new to accepted
- Version changed from 2.9.1 to 2.9.2
#4
@
15 years ago
- Keywords has-patch added; needs-patch removed
- Summary changed from Edit/Updating Theme Files different URLs to Theme-Editor - Relocates to a URL containing full path after a change is saved.
Ok, I think I got this one down!
#5
@
15 years ago
- Keywords commit added
Looks good. I've updated your patch to use add_query_arg(), which is easier to read.
#7
follow-up:
↓ 8
@
15 years ago
Is the only purpose here to move the dir to the end of the URL, so the URL better reflects the file being edited?
#8
in reply to:
↑ 7
@
15 years ago
Replying to nacin:
Is the only purpose here to move the dir to the end of the URL, so the URL better reflects the file being edited?
No, it should fix the file parameter.
Before saving:
localhost/wp/wp-admin/theme-editor.php?file=/themes/twentyten/404.php&theme=Twenty+Ten&dir=theme
After saving:
localhost/wp/wp-admin/theme-editor.php?file=H:\xampplite\htdocs\wp/wp-content/themes/twentyten/404.php&theme=Twenty+Ten&a=te&scrollto=0
The Reporter said, that this breaks his plugins, but for scribu and me it breaks nothing. Maybe it's fixed through [13994].
#9
@
15 years ago
- Keywords commit removed
- Milestone changed from 3.0 to 3.1
These paths became absolute in 2.9 because we added the ability to register a theme directory. While this is technically a regression, I'm not inclined to potentially break custom theme directories at this stage, and would rather move this to 3.1.
I don't believe the reporter said it broke his plugins, only his back button (and that he had no plugins enabled). Also, [13994] didn't fix this.
#11
@
12 years ago
- Keywords close added
I do not think this is a problem any longer. When I edit a file using the editor I am at url :
http://localhost/wp/wp-admin/theme-editor.php?file=style.css&theme=blank[[BR]]
After submitting changes I end on
Proposing we close this ticket.
I confirm the same happens with my 2.9.2 but on mine it doesn’t break the feature so I do not need to use the BACK button. I will try to work on a patch for this.