hook_feature_attributes

Versions
6
hook_feature_attributes($node)

Provide added product attributes via a feature

Return additional attributes for a product based upon features that have been added to a product.

For more information see hook_attributes().

Parameters

$node The node of the product that is to be checked.

Return value

Return an array of attributes which are to be enabled or disabled.

Related topics

Code

contrib-6/ecommerce/ec_product/ec_product.features.api.php, line 27

<?php
function hook_feature_attributes($node) {
  return array('no_discount' => TRUE);
}
?>

Post new comment

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options