Advertisement
Guest User

Untitled

a guest
Jul 1st, 2016
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. $node = node_load(1);
  2. $node->mycustomdata = 'mydata'; // This is the data i want passed through
  3. return node_view($node, 'teaser');
  4.  
  5. function MYMODULE_preprocess_node(&$variables) {
  6. $node = $variables['node'];
  7. $variables['mycustomdata'] = $node->mycustomdata; // Here is where i want to access the data
  8. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement