Closed (fixed)
Project:
Advanced User
Version:
master
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Reporter:
Created:
28 Jul 2006 at 16:39 UTC
Updated:
31 Jan 2007 at 08:46 UTC
Jump to comment: Most recent file
I'm getting
Fatal error: Call to undefined function: t() in ../drupal/modules/advuser/advuser.module on line 6
as an anonymous user, typically after generating a refresh or back operation in the browser on any page within the site, when both the advuser module and caching are enabled. It does not seem to affect authenticated users. It does not appear when caching is disabled.
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | advuser.replace_constant_with_t.patch_0.txt | 1.69 KB | Bèr Kessels |
| #5 | advuser.replace_constant_with_t.patch.txt | 13.29 KB | Bèr Kessels |
| #3 | advuser-remove-t-function.patch.txt | 568 bytes | sillygwailo |
Comments
Comment #1
Albion_Arg commentedSame problem here!
Comment #2
sillygwailoComment #3
sillygwailoAs much as it pains me to do this, I removed the t() function in the attached patch because I think that, since it's in the block of code defining constants at the beginning of the module, the t() function hasn't been declared yet by Drupal.
I'm thinking if we removed the constants and put their values in where they are called (yes, duplication of values), then we can put back the t() function.
Comment #4
Mojah commentedI commented out the t() function and added the constant without the t() function as suggested. I'll test out your suggestion of removing the constants and putting their values in where they are being called, to see if it works.
Thank you.
Comment #5
Bèr Kessels commentedApplies to 4.7 too.
This patch takes another route and simply removes that global, and puts the t() string in the place. yes duplication, but no, not bad.
Comment #6
Bèr Kessels commentedrerolled without whitespace changes.
Comment #7
xamox commentedThis happened to mysite and seems to have messed a bunch of stuff up. Like URL redirection. For instance when you log in, you have to log in 2x. You log in once, it just goes back to the main page and then you have to login again. It changed my default frontpage, and I can't change it back even though it is set in the site settings. I didn't have caching on either and this still has happened. Also it for some reason reset user passwords. I had to manually reset my admin password. And now when I go to the home page URL while logged it will automatically log me out. This error was reported to me by someone else but they said it happened when they tried the password recovery, then that module error was displayed. After that my entire site was broke and I had to manually disable the advuser module. After I did everything was as I mentioned above.
Comment #8
WeRockYourWeb.com commentedWow, sorry to hear about that xamox. I tried this patch as well (advuser.replace_constant_with_t_.patch) to no avail. Going to refrain from using advuser for now.
Comment #9
mcurry commentedThis affects me too, so I'm adding this to "my issues" list. Any idea what's going on here?
Comment #10
mcurry commentedI neglected to mention that I am using the DRUPAL-4-7 distro of advuser.
Also, I am running the Zend Optimizer on PHP 4, might this have something to do with the problem?
PHP Version 4.4.2
Zend Extension 20050606
Zend Optimizer v3.0.1
Comment #11
mcurry commentedSeems to be related to http://drupal.org/node/80770 - due to init-time processing?
Comment #12
mcurry commentedI've just taken over maintainer/owner role for this module. Is this issue still a problem for people? I know it was biting me in the butt a few weeks back, so I'll probably commit this patch to CVS soon.
Please see http://drupal.org/node/108493 - the package build timestamps are bogus - the HEAD package is actually newer than the displayed date, due to a bug/issue in drupal.org CVS integration, so... I don't know when/if that issue will be fixed, and therefore you will have to watch this space, or inspect the project's CVS messages to see if/when a new HEAD package will be built.
Comment #13
mcurry commentedI've checked in another fix to the CVS head. The next package build cycle should update the package, please try it out and let me know if this fixes the problem. (See my prior comment about the package timestamps - the packages are being built even though the timestamps aren't updated.)
Comment #14
(not verified) commented