On Jun 12, 6:14 pm, saidbakr <[email protected]> wrote:
> In other word,
>
> In the controller action some logic will be done and it will return
> either true or false. If it true, I need something to call the html
> helper in the view and then changing all links with title contains the
> text "Edit" or "Delete" to return null or empty string instead of html
> link.
That's not a good way to handle it. Pass your flag (true|false) to the
view:
$this->set( 'flag', $this->myLogic() );
... and then:
if ( !$flag )
{
$html->link(...)
}
Or:
if ( ( $foo['Edit'] || $foo['Delete'] ) && !$flag )
{
$html->link(...)
}
Check out the new CakePHP Questions site http://cakeqs.org and help others with
their CakePHP related questions.
You received this message because you are subscribed to the Google Groups
"CakePHP" 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