uc_product_kit_nodeapi

Versions
5
uc_product_kit_nodeapi(&$node, $op, $arg3 = null, $arg4 = null)
6
uc_product_kit_nodeapi(&$node, $op, $arg3 = NULL, $arg4 = NULL)

Implementation of hook_nodeapi().

Code

contributions/ubercart/uc_product_kit/uc_product_kit.module, line 391

<?php
function uc_product_kit_nodeapi(&$node, $op, $arg3 = NULL, $arg4 = NULL) {
  switch ($op) {
    case 'update':
      $result = db_query("SELECT DISTINCT nid FROM {uc_product_kits} WHERE product_id = %d", $node->nid);
      while ($k = db_fetch_object($result)) {
        $kit = node_load($k->nid, NULL, TRUE);
        $form_state = array(
          'values' => array('nid' => $kit->nid),
          'submit_handlers' => array('node_form_submit'),
        );
        drupal_execute('product_kit_node_form', $form_state, $kit);
      }
    break;
  }
}
?>

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.
  • Web page addresses and e-mail addresses turn into links automatically.

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
Image CAPTCHA
Enter the characters (without spaces) shown in the image.