Forum

Thread tagged as: Question, Runway

Quick Questions

Is there a perch conditional for if something doesn't exist?

Is there a perch conditional for elseif?

Is there a way to limit the number of characters returned from a content region? Either to limit the number of characters that can be entered, or to truncate the returned content (say for Perch Content Custom?)

Paul Bell

Paul Bell 0 points

  • 5 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Is there a perch conditional for if something doesn't exist?

Yes, you can use:

<perch:if not-exists="foo"> </perch:if>

https://docs.grabaperch.com/docs/templates/conditionals/if/

Is there a perch conditional for else if?

There's not currently.

Is there a way to limit the number of characters returned from a content region?

Yes, on output:

https://docs.grabaperch.com/docs/templates/attributes/chars/ https://docs.grabaperch.com/docs/templates/attributes/words/

and count on input:

https://docs.grabaperch.com/docs/templates/attributes/type/textarea/

Brilliant - thanks