[development] form with confirmation (sometimes)

Pierre Rineau pierre.rineau at makina-corpus.com
Thu Jul 2 10:04:31 UTC 2009


BTW, I don't like the node.module implementation of config_form on
delete workflow.

Even worst in comment.module, they do the same stuff accessible directly
to $_POST superglobal.

They should properly do this using a multistep form, I.E. by accessing
variables in the $form_state and playing with the $form_state['rebuild']
option, which they are not apparently doing.

Pierre.

Le jeudi 25 juin 2009 à 10:13 -0700, Michael Prasuhn a écrit :
> Look at node module, specifically node_admin_nodes() and  
> node_admin_nodes_validate() and node_admin_nodes_submit() which are  
> all found in node.admin.inc in Drupal 6. It provides this same  
> functionality - it only shows a confirmation form if the operation is  
> to delete nodes.
> 
> -Mike
> 
> On Jun 25, 2009, at 9:29 AM, Lluís wrote:
> 
> > I have a form to allow deleting some variables. If the deleted item is
> > 'empty' it should be possible to delete it without any problem; but
> > full items should have a 'confirmation' step before deleting them.
> >
> > I have read http://drupal.org/node/387674 and
> > http://drupal.org/node/385640; but in my case I need to pass an array
> > to the confirmation form, and I think it has to be an easier way to
> > allow a "Are you sure you want to do this?".
> >
> > Any hint is welcome.
> >
> > -- 
> > *La vida és com una taronja, què esperes a exprimir-la?
> > *Si creus que l'educació és cara, prova la ignorància.
> > *La vida és com una moneda, la pots gastar en el que vulguis però
> > només una vegada.
> > *Abans d'imprimir aquest missatge, pensa en el medi ambient.
> 
> __________________
> Michael Prasuhn
> 503.488.5433 office
> 971.244.2595 cell
> 503.661.7574 home
> mike at mikeyp.net
> http://mikeyp.net
> 
> 
> 
> 
> 
> 



More information about the development mailing list