Route top level request

2010-09-01 Thread EchoChargen
Hi - I have a 1.2 app that I'm updating to 1.3. I need to send all top level requests like /foo to a controller action (/sites/view/$1) if they are not a valid controller. So in my 1.2 app I had a route like this (incredibly ugly I know): Router::connect('(?!admin|billings|carriers|clips|cliptyp

HABTM 'with' relationship delete() question

2008-05-15 Thread EchoChargen
All - I'm trying to wrap my brain around the HABTM 'with' or 'auto- with' (I've seen this term?) relationship. I think I've got it to a degree, but I need some help. I have the following: Site hasOne Prospectingplaylist (dependent => true) Prospectingplaylist belongsTo Site Prospectingplaylist h

Re: Cake 1.2 Auth Component Step-by-Step

2008-02-22 Thread EchoChargen
I've seen several posts and articles with this type of thing in Users- >login(): if($this->Auth->login()) { $this->redirect($this->Auth->loginRedirect); }else{ $this->data = null; $this->set('erro

Re: Auth Component - Should authError be displayed if session times out?

2008-02-21 Thread EchoChargen
time > on the page but this can be fixed with Baz approach (Cookie). > Baz if you pass twice in befoeFilter, you can detect it by setting a > variable (maybe static) in beforeFiler ? > > On Feb 21, 5:32 am, EchoChargen <[EMAIL PROTECTED]> wrote: > > > Another thing o

Re: Auth Component - Should authError be displayed if session times out?

2008-02-20 Thread EchoChargen
Another thing of note, is if I run through the steps: 1. login, get redirected to what I have in Auth->loginRedirect 2. let session expire 3. click a link to a protected action and get redirected to Auth- >loginAction, and in my case above get a flash message with "your session timed out." 4. At t

Re: Auth Component - Should authError be displayed if session times out?

2008-02-20 Thread EchoChargen
Baz, Your steps above are what I see in my testing as well.I also noticed that when my session times out, auth.redirect was always set in the new session I'd see when hitting step #4. So I did this in my Users- >login method: function login() { $this->disableCache();

Auth Component - Should authError be displayed if session times out?

2008-02-16 Thread EchoChargen
Hello - Using 1.2 beta release 6311 with Auth component. I've set the session timeout to 60 seconds for testing (core.php "high" setting). I'm able to login and get redirected correctly to loginRedirect(). If I sit on a protected page and let the session time out, I get redirected back to the

Re: Customize html outputted by form helper?

2008-02-09 Thread EchoChargen
I'm not sure what you're asking exactly, but here's an example of using some of the options in the form helper: echo $form->input('phone1', array('label' => array('text' => 'Phone Number', 'class' => 'left'), 'maxLength' => '3', 'before' => '', 'class' => 'phone', 'div' => false )); echo $form->in

Re: Model Association Query....stumped

2008-02-08 Thread EchoChargen
I've done the following: Clipranking Model: function findClipByRank($site_id){ return $this->query("SELECT Clipranking.rank, Clipranking.site_id, Clipranking.required, Clip.id, Clip.name, Clip.length FROM cliprankings AS Clipranking, clips AS Clip WHERE Clipranking.site_id = $site

Model Association Query....stumped

2008-02-07 Thread EchoChargen
All - I've been using Mariano Iglesias Bindable behavior with 1.2 beta to nice effect, but I've run into a query I can't figure out. Here's what I have: Team hasMany Clip Team hasMany Site Site hasMany Clipranking A Site can play any of the Clips available in their Team in whatever ranked order

Re: Display form validation error troubles

2008-02-02 Thread EchoChargen
Maybe if you post some of the code, someone will have some suggestions. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe

Re: Display form validation error troubles

2008-02-02 Thread EchoChargen
Neil - I am new Cake user, but I was able to get validation working with forms for different models. By setting the error messages in the model. Here's a snip from my User model: 'city' => array( 'required' => array( 'rule' =

Display Model Validation Messages with Form->month?

2008-01-25 Thread EchoChargen
Good afternoon, I have a form that will collect data for several models. One of them is a creditcards table that has 'ccexmonth' and 'ccexyear' fields. I bumbled around with the form helper until I came up with something, but it seems like there must be a slicker way to do it. I have the proble