I have preview enabled in my Drupal workflow. When I fill out the form for creating a feed_fast node and click "Preview", the URL field is blank on the resulting page (the obvious workaround is to enter the URL again before clicking "Save"). This only happens on new node creation; when editing a node, the URL field is filled in, even after clicking "Preview". It probably happens with regular feed nodes too, but I don't have them enabled.

I think what's happening is that the form code is looking in the node object for the default value of the URL field, but during preview you need to look in the form_state object. So, at the top of hook_form() you need something like this:

  if (array_key_exists('values', $form_state)) {
    $node->url = $form_state['values']['settings']['url'];
  }

(That's just an example; I haven't looked at the code for this module yet.)

Comments

twistor’s picture

Issue summary: View changes
Status: Active » Closed (outdated)