Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Search found 8 matches
Smarty Forum Index
Author Message
  Topic: {strip} bug?
gtozzi

Replies: 10
Views: 28283

PostForum: Bugs   Posted: Fri Oct 27, 2017 11:51 am   Subject: {strip} bug?
I have a question: why do you think a generic text transformation would correctly apply to a formatted text?
It is more than likely it would break the formatting. Which you, evidently, proved yoursel ...
  Topic: {strip} bug?
gtozzi

Replies: 10
Views: 28283

PostForum: Bugs   Posted: Fri Oct 27, 2017 11:49 am   Subject: {strip} bug?

Can you give an example? The example in the docs suggests that nothing but spaces and newlines are lost.


That's right, but it does not account for HTML, so an output like


<input
...
  Topic: {strip} bug?
gtozzi

Replies: 10
Views: 28283

PostForum: Bugs   Posted: Mon Oct 23, 2017 6:21 am   Subject: {strip} bug?
I am now using this


/**
* Smarty plugin
*
* Leaves only one space where multiple spaces are found
*/
public static function mStrip($params, $content, $smarty, &$repeat) ...
  Topic: {strip} bug?
gtozzi

Replies: 10
Views: 28283

PostForum: Bugs   Posted: Mon Oct 23, 2017 5:58 am   Subject: {strip} bug?
I correct myself: that does not work, because it also truncates text inside quotes indiscriminately.
  Topic: {strip} bug?
gtozzi

Replies: 10
Views: 28283

PostForum: Bugs   Posted: Mon Oct 23, 2017 12:33 am   Subject: {strip} bug?
Thank you, that's a good workaround.
  Topic: {strip} bug?
gtozzi

Replies: 10
Views: 28283

PostForum: Bugs   Posted: Sun Oct 22, 2017 4:09 pm   Subject: {strip} bug?
Hi there!

From what i read in the docs (the extra spaces are stripped), I would expect {strip} to "compress" spaces, but always keep at least one.

In fact, it looks like it just strips ...
  Topic: Block append and prepend directives override eachother
gtozzi

Replies: 5
Views: 23148

PostForum: Bugs   Posted: Sun Mar 19, 2017 2:12 am   Subject: Block append and prepend directives override eachother
Thank you for your reply.

Could you please explain me what is the intended way to extend a block in a "child" template by simultaneously appending and prepending to it?
  Topic: Block append and prepend directives override eachother
gtozzi

Replies: 5
Views: 23148

PostForum: Bugs   Posted: Sat Mar 18, 2017 5:55 pm   Subject: Block append and prepend directives override eachother
Hi there!

I've been using Smarty for a very long time and this is the first time (maybe) I found a bug so, first of all, let me express my gratitude and congratulations for creating such a stable, ...
 
Page 1 of 1
All times are GMT
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP