Opened 13 years ago
Closed 12 years ago
#19130 closed defect (bug) (invalid)
current wp-login.php call to wp_admin_css() bypasses its own filter
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 2.6 |
Component: | General | Keywords: | has-patch |
Focuses: | Cc: |
Description
The current situation in wp-login.php looks like the following:
wp_admin_css( 'login', true ); wp_admin_css( 'colors-fresh', true );
Looking at /wp-includes/general-template.php and wp_admin_css( $file = 'wp-admin', $force_echo = false );
tells that this bypasses the filter calls as the function returns if $force_echo
is true. The filters are called after that. This doesn't make sense as the filter will never work this way. Changing wp_admin_css()
is no option, so I suggest to change the calls to it in login_head.
Attachments (1)
Change History (10)
#6
@
13 years ago
- Keywords close added
- Version changed from 3.2.1 to 2.6
Comment from nacin:
Core CSS files will get processed via WP_Styles, so the filter isn't very helpful anymore.
The filter wp_admin_css
will never be fired for core files, no matter if $force_echo
is true or false. If you use a custom file the filter can be used.
Behaviour introduced in #7011.
#7
@
13 years ago
- Cc Ninos Ego added
- Version changed from 2.6 to 3.3.1
I hope in the next version you can fix this bug. Because I want to do all things with wordpress, and this issue is like a jail for me. I have got a custom login stylesheet. 80% of the code are !important atribute. Beyond my login page is not compatible with other browsers..
#8
@
13 years ago
- Version changed from 3.3.1 to 2.6
Version number indicates when the bug was initially introduced/reported.
#9
@
12 years ago
- Keywords close removed
- Milestone Awaiting Review deleted
- Resolution set to invalid
- Status changed from assigned to closed
As @ocean90 notes in comment:6, the wp_admin_css
filter will never be fired for core files — if a custom file is passed, the filter will fire. This is a feature, not a bug.
In a way, it is conceptually similar to the admin_body_class
filter: core admin body classes can't be filtered, but new ones can be tacked on.
Duplicate of #14559?