I think you can do this in the element:

<?php echo serialize(array('many' => 'vars')); ?>

and this in the view:


<?php

$vars = unserialize($this->renderElement(stuff...));

export($vars)

echo $many ;

?>


On Oct 31, 5:44 pm, Defranco <[EMAIL PROTECTED]> wrote:
> Hi,
>
> Besides the standard html returned from a element while using
> renderElement - is possible to return variables from a view like when
> you pass an argument as reference to a function?
>
> I'm rendering a element and it is returning an html (string) but I
> would like to get a collection of variables from it instead of just a
> string that it normally returns -- is it possible?  -- is there some
> workaround that I can use to return a collection of variables (array
> for example) from a single render element?
>
> thanks
>
> DeFrancoI think you can do this in the element:

<?php echo serialize(array('many' => 'vars')); ?>

and this in the view:


<?php

$vars = unserialize($this->renderElement(stuff...));

export($vars)

echo $many ;

?>


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to