WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to specify which css file gets loaded when the user clicks on "Appearance > Editor". However, its always loading style.css for some reason.

Any way to enforce that a specific file gets loaded there?

share|improve this question
up vote 2 down vote accepted

This seems to be controlled by global $file variable, which is filled from request (GET or POST) by WordPress. So you will need to pass file you want in request or hook somewhere and override value of the variable. If latter be careful that you don't lock editing to single file altogether.

See source for details.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.