[development] nodeapi data flow

Earnie Boyd earnie at users.sourceforge.net
Mon Sep 8 11:26:50 UTC 2008

Quoting Eric-Alexander Schaefer <eric.schaefer at eas-consulting.de>:

> FGM schrieb:
>> Maybe you are looking for something like http://drupal.org/node/112180 ?
> No. I want to know with which $op's hook_nodeapi() is called and the 
> state of the node data during the call.
> E.g.: When the user clicks "preview", hook_nodeapi() is called with 
> $op='validate'. $node contains all the fields from the form in 
> unprocessed state.
> I am trying to fix a bug in scheduler.module. The user enters a time 
> and date for a node to be published automatically (like "2008-09-10 
> 10:00:00). On $op=='validate' the entered string is converted to a 
> timestamp if $node->publish_on is nonnumeric (eg a string). The same 
> is done on $op=='presave'. Works like a charm, except if the user 
> clicks "preview" a second time. I don't know why. The form processing 
> should be the same as for the first preview.
> Maybe I need to dig into node.module and find out which functions are 
> called and which how the node data is processed. Sleep is overrated 
> anyway. ;-)

Is it possible that the FAPI #validated is set to TRUE so that validate 
is no longer executed?

Earnie -- http://for-my-kids.com/
-- http://give-me-an-offer.com/

More information about the development mailing list