Problem passing URL variables in post form submission with CakePHP FormHelper

Hi there,

I'm writing my first CakePHP application and am just writing the second part of a password reset form where a user has received an email containing a link to the site and when they click it they're asked to enter and confirm a new password.

The url of the page is like this:


The view is like:

<?php echo $form->create('User', array('action' => 'reset_password_confirm')); ?>
    echo $form->input('password', array('label' => 'Password'));
    echo $form->input('confirm_password', array('type' => 'password', 'label' => 'Confirm password'));
    echo $form->hidden('static_hash');
<?php echo $form->end('Reset password'); ?>

However this produces a form like:

The problem is the user id (8 in this case) is being added to the form action. It's not really a problem here, but when I want to pass through the hash to my controller:

function reset_password_confirm($static_hash=null) {
    // function body

$static_hash is now populated with 8 rather than the hash from the URL.

I know I could sort this out by creating the form tag myself rather than using $form->create but is there a more cakey way of doing this?