[development] Question about Forms API?

Richard Morse remorse at partners.org
Fri Dec 1 14:47:37 UTC 2006

On Nov 30, 2006, at 5:15 PM, Karoly Negyesi wrote:

>> (I also set '#input' to false, but that may be unnecessary),
> It's not 'unnecessarry' but 'fundamentally broken'. If #input is  
> FALSE then user submitted values will never got to your element and  
> the #value of the element won't even be created if it does not  
> exist and $form_values won't get the #value... this is not  
> something you want.

The items are hidden values, though, not user input values.  The  
issue is that I need to preserve 'q', 'sort', and 'order' values  
across form submission (the form is submitted via GET, because I need  
to preserve the form values across clicks in a tablesort_sql table).   
The value for 'q' is needed to allow this to work with or without  
clean urls, but it never needs to be set by the user.  'sort' and  
'order' would only change from clicking on a link created by  
tablesort_sql, so again it isn't being changed by the user in the  
context of the form.  To set the values, I actually grab them out of  
$_REQUEST, because I don't want the previous values that the form  
had, I want the values that are new from the user.

If you'd like to see this in action, the module I'm working on is  


More information about the development mailing list