title: Wordpress do_shortcode function while calling the_slug to replace the category attribute
body: <p>I am trying to use this shortcode in my theme and I want the category to become the slug for whatever page it's on.</p>
  
  <p><code>&lt;?php echo do_shortcode('[image-carousel category="'.the_slug().'"]'); ?&gt;</code></p>
  
  <p>Now while this does achieve that function, it is also spitting out the actual text of the slug right above the image. I tried using variables, also tried escaping the quotes, and a bunch of other stuff yet the above script is the only way I've gotten it to display the proper image, the only problem is the visible text.</p>
  
  <p>How can I avoid that from happening?</p>