147 posts Get in the spotlight
  • Has been part of the Envato Community for over 4 years
  • Has sold $250,000+ on Envato Market
  • Had an item featured in an Envato Bundle
  • Has collected 1+ items on Envato Market
+6 more
FamousThemes says

Could some one give me a little help here :)

I have the simple shortcode:

function services_box( $atts, $content = null) 

{ 

 extract(shortcode_atts(array( 

        'title'      => '', 

        ), $atts));

   return '<div class="services_content"><h6>'.$title.'</h6><p>'. do_shortcode($content) . 

 '</p></div>'; 

} 

add_shortcode('service', 'services_box'); 

Adding in editor the following:

[service title=Ut enim ad minim veniam] Sed do eiusmod tempor incididunt ut labore et Ut enim ad minim veniam, quis nostrud. [/service]

The problem is that the TITLE it shows only the first word from my phrase “Ut”, and stops when the space comes.

Ut

Sed do eiusmod tempor incididunt ut labore et Ut enim ad minim veniam, quis nostrud.

Does anyone knows how to fix the space issue?

Thanks.

1028 posts
  • Has referred 500+ members
  • Has sold $500,000+ on Envato Market
  • Has collected 50+ items on Envato Market
  • Elite Author: Sold more than $75,000 on Envato Market
+6 more
ThemeBlvd says

Have you tried using quotes?

[service title="Ut enim ad minim veniam"] Sed do eiusmod tempor incididunt ut labore et Ut enim ad minim veniam, quis nostrud. [/service]
2580 posts Put a Donk On It
  • Has referred 200+ members
  • Has sold $250,000+ on Envato Market
  • Has collected 10+ items on Envato Market
  • Elite Author: Sold more than $75,000 on Envato Market
+10 more
ThemeProvince says

You know you should have your short atts in double quotes. Like Jason said above ^

147 posts Get in the spotlight
  • Has been part of the Envato Community for over 4 years
  • Has sold $250,000+ on Envato Market
  • Had an item featured in an Envato Bundle
  • Has collected 1+ items on Envato Market
+6 more
FamousThemes says

Problem fixed.

Damn that was simple :), quotes fixed it. I gues I am really tired forgeting about the quotes.

Thanks ThemeBlvd and Phoenix

by
by
by
by
by
by