modified executeIndex in IndexSucces?
i have
public function executeIndex(sfWebRequest $request)
{
$this->plans = Doctrine_Core::getTable('Messages')
->createQuery('a')
->execute();
}
I can add ->limit(5);
and how can i this make in indexSuccess.php? for 开发者_Python百科example i add:
<input type="text" id="limit">
<?php foreach ($messages as $i => $message): ?>
echo $message->getId();
<?php endforeach; ?>
how to send data directly to executeNew?
if you define the property correctly in the action you can use it in the view:
public function executeIndex() {
$this->messages = // whatever way you fetch the data
}
in the view you can now use the $messages variable.
Is this what you are trying to accomplish?
精彩评论