I'm using drupal 7
I'm writing a custom hook_form_alter something like this
function mymodule_form_alter(&$form, &$form_state, $form_id){
if($form_id == "rating_node_form")
{
// Do something
}
}
it seems that both the node add form and the node edit form are using the same form ID. I'm wondering if there is a way to determine weather you are editing or adding a node and make changes to the form accordingly. Do they always have to be the same exact form?