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

htmlenties und unicode

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Language: German
View previous topic :: View next topic  
Author Message
the-styler
Smarty Rookie


Joined: 12 Jul 2004
Posts: 25

PostPosted: Tue Jul 13, 2004 3:11 pm    Post subject: htmlenties und unicode Reply with quote

gibt es eine funktion die den gleichen zweck hat wie htmlenties in php auch in smarty?

und irgendwo habe ich eine funktion gesehen, die meine variable in den unicode umwandelt. kann mir einer helfen?

ach ja und kann ich mehrere auf eine variable anwenden. in php kann ich sie ja verschachteln geht das in smarty auch? wenn ja wie?
Back to top
View user's profile Send private message
messju
Administrator


Joined: 16 Apr 2003
Posts: 3336
Location: Oldenburg, Germany

PostPosted: Tue Jul 13, 2004 3:49 pm    Post subject: Re: htmlenties und unicode Reply with quote

the-styler wrote:
gibt es eine funktion die den gleichen zweck hat wie htmlenties in php auch in smarty?


http://smarty.php.net/escape

Quote:
und irgendwo habe ich eine funktion gesehen, die meine variable in den unicode umwandelt. kann mir einer helfen?


du kannst php-funktionen als modifier einsetzen:
{$var|utf_encode}

Quote:
ach ja und kann ich mehrere auf eine variable anwenden. in php kann ich sie ja verschachteln geht das in smarty auch? wenn ja wie?


ja, du kannst die modifier einfach aneinander hängen:
{$var|utf8_decode|escape:javascript|strtoupper}
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Language: German All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


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