We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

truncHTML not working

Development and Programming

fxidesigns's avatar
fxidesigns
131 posts
16 years ago
fxidesigns's avatar fxidesigns

Moderator’s note: Moved to Plugins: Tech Support (Not a first-party plugin).

I have installed the latest version of truncHTML and am using the following call;

{exp:trunchtml chars=“300” ending=”<a >read on</a>”}
{body}
{/exp:trunchtml}

However when I change the chars= setting I get no difference in the amount of characters returned. Any ideas?

Thanks, Joe

       
Derek Jones's avatar
Derek Jones
7,561 posts
16 years ago
Derek Jones's avatar Derek Jones

Do you have curly quotes in your template like you do in your sample above?

       
fxidesigns's avatar
fxidesigns
131 posts
16 years ago
fxidesigns's avatar fxidesigns

What’s curly quotes? I am using the quotes that are on the shift ’ key… like this “

       
fxidesigns's avatar
fxidesigns
131 posts
16 years ago
fxidesigns's avatar fxidesigns

Ok… I used double quotes as in ” however when I changed to single quotes like ’ it seems to work. Thats weird… for every other EE expression I use double quotes.

       
Derek Jones's avatar
Derek Jones
7,561 posts
16 years ago
Derek Jones's avatar Derek Jones

Did you cut and paste this from somewhere? “ and ” are quite different from " and would not result from typing them with the double-quote key on your keyboard.

       
fxidesigns's avatar
fxidesigns
131 posts
16 years ago
fxidesigns's avatar fxidesigns

Yep that was it… Actually I copy & pasted from the sample code here on the plugin part of the EE website. I wonder why the quotes are different… anyway its all good now!!

THANKS!! Joe

       
silenz's avatar
silenz
1,648 posts
16 years ago
silenz's avatar silenz

Glad to hear it’s working now.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.