WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

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 have created a Theme Options page using Settings API so now I need to style it using CSS. Instead using function like this inside functions.php

function mytheme_add_init() {
if ( is_admin() ) {
    wp_enqueue_style("functions", $get_path."/css/admin.css", false, "1.0", "all");

add_action( 'wp_enqueue_scripts', 'mytheme_add_init' );

I am using <?php include (TEMPLATEPATH . "/functions/admin_css.php"); ?> directly inside my file responsible for creating my Theme Options Page. Reason for this approach is that I will use some images (their path will be dynamicly generated using get_template_directory_uri() thingy) inside my Options Page.

So what really want is to add my theme to WordPress.org repository.

Question: Because I am using that approach will I suffer consequences like being my theme rejected by WordPress Theme Review Team ?

share|improve this question
up vote 2 down vote accepted

Yes, that will get rejected. It's also wholly unnecessary, since you can use relative paths to the images in your CSS file, you don't need to have them dynamically generated.

share|improve this answer
Note: you'll also get rejected for using TEMPLATEPATH or get_bloginfo( 'template_directory' ), instead of get_template_directory_uri(). – Chip Bennett May 16 '13 at 14:50

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.