Re: [SMARTY] parameters from template to php-script
| From: | Jason Sweat | Date: | Sat, 03 May 2003 20:54:26 +0000 |
| Subject: | Re: [SMARTY] parameters from template to php-script | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-9463@lists.php.net to get a copy of this message | ||
Horst,
Try http://www.zend.com/zend/art/art-sweat4.php
for understanding how
PHP can receive inputs. You can construct URL's with GET parameters in
Smarty. You can also use Smarty to create HTML forms to POST to a PHP
script.
HTH
Jason
----- Original Message -----
From: "Horst Tellioglu" <horst@tellioglu.com>
To: <smarty-general@lists.php.net>
Sent: Saturday, May 03, 2003 4:46 AM
Subject: [SMARTY] parameters from template to php-script
> Hi,
>
> I am new to Smarty and I wonder if it is possible to set parameters
from the
> template which can be used by the php-script. (I am used to writing
JSP
> Custom Actions and I am looking for something similar here.)
>
> For example if I retrieve a list of customers from a database and
store them
> into an array I can iterate over them with:
>
> {foreach from=$customers item=cust}
> name: {$cust->name}<br>
> {/foreach}
>
>
> What I am looking for is a way to specify which customers to look up
in the
> database. Is there a way to do that with Smarty? As I said I am
totally
> new to this. Maybe I am overlooking something obvious here.
>
>
> Thanks for any help!
> Horst Tellioglu
>
>
> --
> Smarty General Mailing List (http://smarty.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>