Active
Project:
Track
Version:
6.x-0.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 Mar 2010 at 06:17 UTC
Updated:
31 Jul 2011 at 17:49 UTC
Visiting the Drupal path track/add results in this error message:
Fatal error: Call to undefined function node_add() in /home/drupal/sites6/any/modules/_geo/track/track.module on line 25
My guess is that it's an issue with 5.x to 6.x upgrades. I found these two things in the module upgrade notes that seem related:
http://drupal.org/node/114774#module_load_include
http://drupal.org/node/114774#node_add_summary
Comments
Comment #1
aubreymoore commentedI get the same error when I click on "Track list | Track upload" on the Navigation menu. Apparently, this menu item calls the wrong URL: "track/add".
I fixed the problem on my site by disabling the ""Track upload" menu item and creating a new one to replace it. My new menu item is "Upload a track" and this calls the URL "node/add/track".
Comment #2
gadzuk commentedConfirmed bug, thanks!
Comment #3
emorling commentedIt appears the function does not exist, because the module has not yet been loaded.
Simply include this code snippet, straight before node_add().
Comment #4
sanduhrsThere is a function just for that.
http://api.drupal.org/api/function/module_load_include/6
Comment #5
richH commentedHi,
I added this code to the beginning of 'sites/all/modules/track/track.module' and it works fine: