# What is wrong here? Variable to working

**URL:** <https://www.phphelp.com/t/what-is-wrong-here-variable-to-working/31840>\
**Category:** Help with WordPress\
**Created:** [May 11, 2020, 10:07am UTC](https://www.phphelp.com/t/what-is-wrong-here-variable-to-working/31840 "2020-05-11T10:07:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dsdoyle](https://www.phphelp.com/letter_avatar_proxy/v4/letter/d/dc4da7/32.png) [@dsdoyle](https://www.phphelp.com/u/dsdoyle)\
**Post date:** [May 11, 2020, 10:07am UTC](https://www.phphelp.com/t/what-is-wrong-here-variable-to-working/31840/1 "2020-05-11T10:07:27Z")

</div>

Hello,

What am I doing wrong here:

```auto
<?php<br>
$css = "black";<br><br>

if ( !function_exists( 'child_theme_configurator_css' ) ):
function child_theme_configurator_css() {<br>
    wp_enqueue_style( 'chld_thm_cfg_ext1', trailingslashit( get_theme_root_uri() ) .<br> 'gemtechllc/css/base.css' );<br>
    wp_enqueue_style( 'chld_thm_cfg_ext2', trailingslashit( get_theme_root_uri() ) . <br>'gemtechllc/css/'.$css.'.css' );
}
endif;<br>
?>

```

If I do echo $css it works fine, but with the code I get nothing.

Please advise.

Thank you,

Don

---

<div class="post-metadata">

**Author:** ![astonecipher](https://www.phphelp.com/user_avatar/www.phphelp.com/astonecipher/32/2797_2.png) [@astonecipher](https://www.phphelp.com/u/astonecipher)\
**Post date:** [May 11, 2020, 5:38pm UTC](https://www.phphelp.com/t/what-is-wrong-here-variable-to-working/31840/2 "2020-05-11T17:38:42Z")

</div>

$css doesn’t exist inside the function

---

<div class="post-metadata">

**Author:** ![dsdoyle](https://www.phphelp.com/letter_avatar_proxy/v4/letter/d/dc4da7/32.png) [@dsdoyle](https://www.phphelp.com/u/dsdoyle)\
**Post date:** [May 11, 2020, 8:12pm UTC](https://www.phphelp.com/t/what-is-wrong-here-variable-to-working/31840/3 "2020-05-11T20:12:57Z")

</div>

Thank you! 🙂
