|
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 |
Oliver Smarty Rookie
Joined: 11 Nov 2014 Posts: 6
|
Posted: Tue Nov 11, 2014 7:26 am Post subject: Smarty-Variable in PHP verwenden |
|
|
Hallo zusammen,
ich steh auf'm Schlauch und hoffe, hier kann mir jemand runterhelfen:
ist es möglich, direkt aus PHP raus auf Smarty-Variablen zuzugreifen? Ich meine NICHT aus HTML-Dateien sondern tatsächlich aus dem laufenden PHP-Code raus.
Nur mit $name ist die Variable leer, in geschweiften Klammern gibt's einen Fehler und $Smarty.name ist auch leer.
Was überseh ich da?
Danke und liebe Grüße
Oliver |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
|
Back to top |
|
Oliver Smarty Rookie
Joined: 11 Nov 2014 Posts: 6
|
Posted: Wed Nov 12, 2014 7:06 am Post subject: |
|
|
vielen Dank für den Tipp.
Aber, wenn ich "$all_tpl_vars = $smarty->getTemplateVars();" in mein Skript einfüge, bekomme ich einen Netzwerkfehler (500, internal Server error) und die Seite bleibt komplett weiß. Kannst Du mir da bitte auch noch einen Hinweis gegen.
Danke und einen schönen Tag
Oliver |
|
Back to top |
|
U.Tews Administrator
Joined: 22 Nov 2006 Posts: 5068 Location: Hamburg / Germany
|
Posted: Wed Nov 12, 2014 4:01 pm Post subject: |
|
|
Da musst Du genauere Angaben machen wo, wie und wann Du die Variablen abfragen willst. |
|
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
|