Call to undefined function drupal_get_path() - taxonomy_vtn.module 5.x-1.x-dev
vpiotr - May 22, 2008 - 20:37
| Project: | Taxonomy VTN |
| Version: | 5.x-1.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
I have prepared version for Drupal 5.x.
See attached file. Please upload in appropriate format.
| Attachment | Size |
|---|---|
| taxonomy_vtn-5.x-1.x-dev.zip | 57.56 KB |

#1
Note: only main module is modified / tested. Status of "taxonomy_vtn_blocks" sub-module is unknown.
#2
Hi,
thanks, i submit your code to dev branch.
#3
#4
There is a small error in the file taxonomy_vtn.info
When I open up the Module activation screen the module reads
Depends on: Array (missing)
Change line
dependencies[] = taxonomy
to
dependencies = taxonomy
Results in the Module activation screen saying
Depends on: Taxonomy (enabled)
#5
just see dev release not here, but here: http://drupal.org/node/261703
there and here is:
; $Id: taxonomy_vtn.info,v 1.1.2.1 2008/04/22 23:49:05 tomaszx Exp $name = Taxonomy VTN
description = "Taxonomy VTN - vocabularies, terms and nodes"
package = Taxonomy VTN
dependencies = "taxonomy"
core = 5.x
without array.
#6
great work. subscribing. thanks
#7
I have been getting this error intermittently:
Fatal error: Call to undefined function drupal_get_path() in ...\modules\taxonomy_vtn\taxonomy_vtn.module on line 45
#8
This is build-in function (drupal_get_path), verify that you use at least Drupal 4.6
#9
Thanks for your reply. I am using drupal 5.7 with MySql 5.0.18 & php 5.1.1, running garland theme.
I noticed that the drupal_get_path() error usually happens when the user is not logged in. So it appears that even though i have set taxonomy_vtn permissions to allow anonymous user to browse, it gives this error... Please do you have any ideas on the best way to fix it?
Fyi - I also get another error when I want to change seetings using: admin/settings/taxonomy_vtn
warning: Invalid argument supplied for foreach() in ....\includes\form.inc on line 949.
#10
Sorry, no idea why the first error appears.
The second error I see too, but as far as I know it does not affect the configuration page.
Maybe somebody will try to find what is wrong in it, meanwhile you can use it "as is"...
#11
Ok. The thing is that when the "Call to undefined function drupal_get_path()" error happens I can not use the system.... Any link like going to "home" stops working and gives the error. The only way around it at that stage is to go to a link like admin/.... and then try and re-log into drupal.
#12
It appears that I have fixed the bug by putting this condition in function taxonomy_vtn_init() :
if (function_exists('drupal_get_path'))
{
....
}
see these links for similar issues with drupal_get_path:
http://drupal.org/node/200395
http://drupal.org/node/157157
Thanks.
#13
I have the same problem. How did you fix it? I try without results.
Thank's
sergio
#14
Fix described above worked. See: http://drupal.org/node/261670#comment-886125
#15
I read it...but I'm very poor in php...and english too...
In which file I found it:
if (function_exists('drupal_get_path'))
{
....
}
and how did you fill your "...". Could you attach your modified file?
Sorry and thank's a lot.
Sergio
#16
Subscribing, greetings, Martijn
#17
Hello,
why in the drupal 5 port the "exclude vocabs" and "exclude terms" form fields have been eliminated?
In the corresponding source code all related code lines have been deleted.
It would be great for me to use VTN on drupal5 *omitting* some taxonomies.
TIA