[development] Form adding query parameters

nan wich nan_wich at bellsouth.net
Fri Oct 1 14:11:16 UTC 2010


Thanks, Steven. That was real close, but should be:
  $form_state['redirect'] = array($_GET['q'], $r);
  
 
Nancy
 
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.



________________________________

From: Steven Jones
The actual redirection of forms is handled by drupal_redirect_form: 
http://api.drupal.org/api/function/drupal_redirect_form/6

Which looking at the code, passes the $form_state['redirect'] to drupal_goto.

drupal_goto has a second argument for the query string, so I think the end of 
your form submit function may want to look something like:

drupal_set_message("going to $r");
$form_state['redirect'] = array($_GET['q'], array('query' => $r));
drupal_set_message(print_r($_SESSION, true));
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20101001/e76b100d/attachment.html 


More information about the development mailing list