Hi
If I tried to edit a taxonomy with a file field, when I click the button upload/remove, I got an error saying "An illegal choice has been detected. Please contact the site administrator.", and under the Parent terms - only global terms are allowed to be selected.
Tracing down the code at line 187, the path_is_admin(current_path()) gave a FALSE value where I believe what the problem is. As I'm clicking the upload/remove button, current_path() function gave a correct value of [ file/ajax/XXXXXX ], but is it not an admin path according to path_is_admin.
I wonder is there any potential fix on this issue, seems like it doesn't work correctly with file.module, not sure if it is something we need to fix the ajax call in file.module though.
| Comment | File | Size | Author |
|---|
Comments
Comment #1
delta commentedHi, This is looking bad... Do you find a solution / alternative configuration ?
Thanks to report.
Comment #2
drikc commentedHello, I've just created another issue which is related to the
path_is_admin(current_path())condition: #2508826: Taxonomy autocomplete suggestion and the affiliate on user's domain permissionUsing hook_admin_paths() could allow to change a given path to be an "admin" one, but don't know actually if there is side effects to doing so?....
Comment #3
bohartD7 reached its EOL back in January 2025, and there is no active release for D7 for this module.
Neither development nor support is planned for D7.
All D7-related issues (especially those with 10+ years of inactivity) are marked as outdated in a bunch.
If/once the issue still arises in D11+ versions, please create a follow-up issue.
Thanks!