very good since I could easily pass the variable to determine what to
paginate rather than index, open and closed functions.
Just been trying to add
Router::connect('/tickets/open',
array('controller' => 'tickets', 'action' => 'index'),
array(
'pass' => array('type'),
'type' => 'open'
)
-----Original Message-----
From: cake-php@googlegroups.com [mailto:cake-php@googlegroups.com] On Behalf
Of Miles J
Sent: January-24-10 10:39 PM
To: CakePHP
Subject: Re: Routes Pass
Well whats your current setup? And why is it not working?
On Jan 24, 6:04 pm, "Dave" <make.cake.b...@gmail.com> wrote:
> I am having some problems trying to pass a variable in my routes.
>
> I have my standard index($type = null) function for pagination.
>
> I want to pass "open" or "closed" as the $type so the user can view
> all open cases or closed cases if they wish. The $type variable just
> gets passed inside the function to determine which records to pull or
> all if null
>
> so the url would be
> tickets/ or
> tickets/open or
> tickets/closed
>
> Any ideas?
>
> Thanks
>
> Dave
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 cake-php@googlegroups.com To
unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group
cake-php+at http://groups.google.com/group/cake-php?hl=en
No virus found in this incoming message.
Checked by AVG - www.avg.com
Version: 9.0.730 / Virus Database: 271.1.1/2636 - Release Date: 01/24/10
04:03:00
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 cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
No comments:
Post a Comment