|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
andaris Smarty n00b
Joined: 10 Apr 2012 Posts: 2
|
Posted: Tue Apr 10, 2012 5:37 pm Post subject: escape_html: kein Variableninhalt bei Strings mit Umlauten |
|
|
Hallo Leute,
bei mir tritt unter Smarty 3.1.8 folgendes Problem auf:
wenn ich escape_html für meine Templates mittels Code: | $smarty->escape_html = true; | aktiviert habe, werden Strings, die Umlaute enthalten, nicht an Smarty übergeben.
Die Inhalte kommen aus einer mySQL-Datenbank (latin1), das Smarty-Charset mittels Code: | define(SMARTY_RESOURCE_CHAR_SET, 'ISO-8859-1') | festlegen hat nichts gebracht.
Kennt jemand dieses Phänomen und kann mir helfen?
Danke |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
Posted: Tue Apr 10, 2012 5:59 pm Post subject: |
|
|
Code: | define('SMARTY_RESOURCE_CHAR_SET', 'ISO-8859-1') |
Muss vor dem Include von Smarty.class.php stehen. Hast Du das?
Und beachte die Quotes. |
|
Back to top |
|
andaris Smarty n00b
Joined: 10 Apr 2012 Posts: 2
|
Posted: Wed Apr 11, 2012 8:01 am Post subject: |
|
|
Hallo U.Tews,
danke für deine rasche Antwort. Das hab ich gemacht, hat aber leider nichts geholfen. Inzwischen bin ich draufgekommen, dass es irgendwo beim Datenaustausch durch die zwei verschiedenen bei mir verwendeten Charsets (ISO, UTF-8 ) Probleme gibt, ich hab nun als "saubere Lösung" das ganze Projekt auf UTF-8 migriert, nun läufts ohne Mucken
Danke |
|
Back to top |
|
|
|
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
|