Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: Auto trim list items
phiw13 wrote #319759:
it is an opt-in feature, correct?
FWIW, I think it is the correct thing todo. If you really want that space before the separator, add it manually (and in most cases, a non-breaking space is probably more appropriate).
Currently it is opt-in (via trim
), the question is: should be semi-automatic? Say, if break
starts or ends with a space (like in break=", "
), should we trim the list items, unless told otherwise?
And thanks you both, appreciated!
Offline
Re: Auto trim list items
etc wrote #319760:
Currently it is opt-in (via
trim
), the question is: should be semi-automatic? Say, ifbreak
starts or ends with a space (like inbreak=", "
), should we trim the list items, unless told otherwise?And thanks you both, appreciated!
I don’t think you should trim the space in break=", "
, after all it looks like the user has specified it thus. If, on the other hand, TXP or PHP generates extra spaces, yeah, those could go.
(and it is grammatically correct in most languages to have that space there)
Where is that emoji for a solar powered submarine when you need it ?
Sand space – admin theme for Textpattern
Offline
Re: Auto trim list items
phiw13 wrote #319761:
I don’t think you should trim the space in
break=", "
, after all it looks like the user has specified it thus. If, on the other hand, TXP or PHP generates extra spaces, yeah, those could go.
No, we won’t trim the space in break
, and txp/php does not generate extra spaces. That’s the users themselves that introduce them by prettifying the code:
<txp:category_list>
<txp:category />
</txp:category_list>
is actually
newline+4spaces+<txp:category />+newline
And the space surrounding <txp:category />
is not always desirable in the final output.
Offline