title: Silverstripe. setFormAction causes error
body: <p>I have a signup form:</p>
  
  <pre><code>function SignupForm() { 
  
        $fields = new FieldSet( 
           new TextField("FirstName", "First name"), 
           new TextField("Surname"), 
           new EmailField("Email", "Email address") 
        );    
     $submitAction = new FieldSet(new FormAction("SignupAction", "Sign up")); 
     $required = new RequiredFields("Email"); 
  
        $SignupForm = new Form($this, "SignupForm", $fields, $submitAction, $required);
  
  
  
        return $SignupForm; 
     }
  
     function SignupAction($data, $form) {
  
        $member = new Member(); 
        $form-&gt;saveInto($member);
  
        $member-&gt;write(); 
  
        if($group = DataObject::get_one('Group', "ID = $this-&gt;defaultGroupID")){ 
           $member-&gt;Groups()-&gt;add($group); 
           Director::redirect('thanks-for-registering/'); 
        }else{ 
           Director::redirect('registration-failed/'); 
        }
  
     }
  </code></pre>
  
  <p>Which runs fine from the homepage, however it appears on every page and sub page on the site so I need to set the form action.</p>
  
  <p>I have tried adding this:</p>
  
  <pre><code>$SignupForm-&gt;setFormAction(Director::baseURL().'home/SignupAction');
  </code></pre>
  
  <p>before return $SignupForm and I get the following error when I submit the form (from anywhere)</p>
  
  <pre><code>Missing argument 2 for Page_Controller::SignupAction()
  
  function SignupAction($data, $form) { 
  68 
  69        
  70       $member = new Member(); 
  71       $form-&gt;saveInto($member); 
  .....
  </code></pre>
  
  <p>What is going on here?</p>
  
  <p>Thanks</p>