Hello,
I receive the following error message when the checkbox "Redirect on User Edit page" is activated:
warning: Missing argument 2 for user_category_load(), called in D:\DEVELOPMENT\xampp\www\mysite.tld\includes\menu.inc on line 410 and defined in D:\DEVELOPMENT\xampp\www\mysite.tld\modules\user\user.module on line 1160.
I have to un-install the module to get rid of it. De-activating the checkbox does not help.
I use Drupal 6.19 with content_profile 6.x-1.0 on PHP 5.2.
Please let me know if you need more information.
Thank you very much for this great module. It's such a big usability improvement in profile handling! :)
Stefan
Comments
Comment #1
Q2U commentedSame problem here...
Account Profile 6.x-1.x-dev (2010-Dec-01)
Comment #2
kenorb commentedAre you using me module?
If yes, it's duplicate of: #803702: Missing argument 2 for user_category_load()...
and: #929344: Integration with 'me' module
Workaround: http://drupal.org/node/803702#comment-3456186
Test as well this patch:
#929344: Integration with 'me' module
Comment #3
design.er commentedno, I'm not using the 'me' module.
Comment #4
kenorb commentedmenu.inc on line 410
user.module
So it's probably some conflict with other module, which uses 'load arguments' in hook_menu
I haven't got idea why does it happen.
Can you test the patch provided here?
#929344: Integration with 'me' module
Comment #5
guidot commentedUsing the latest dev I get the same error-messages as #1 and additionally an "Access denied". I'm logged in as user 1.
I tried patch 929344-1 from #929344: Integration with 'me' module (in comment #5) without success.
Of all enabled modules on my site I have found the following files in sites/all/modules contain a hook_menu (simply by grepping for "Implementation of hook_menu", is there a better way?):
Don't know if that helps. If you have any idea what else I could do to help, let me know.
Comment #6
kenorb commentedIf you have access to command line, can you search for "load arguments" and "menu_alter"
Thanks.
Comment #7
guidot commentedThis is what I got (excluding disabled modules):
Comment #8
robotjox commentedsame problem here - subscribing
Comment #9
lewie6 commentedsame problem too
Comment #10
lewie6 commentedi had some hook_menu_alters in a custom module. when i removed them and 'rebuilt menu' (using devel) the error goes away.
Comment #11
szantog commentedHi all!
I attach a tarball with some other correction. Please try it in a dev site, imho it fixes this problem too.
Comment #12
kenorb commentedComment #13
gedur commentedHi! Thanks for your solution but I can apply any of your patchs , it gives me an error on some lines:
Hunk #1 FAILED at 57.
Hunk #2 succeeded at 147 (offset 27 lines).
Hunk #3 FAILED at 129.
In the folder the are two patchs, Do I need to appy both sequentially?
Thx
Comment #14
kenorb commentedComment #15
snowmountain commentedI also have this same warning, different line numbers, on page /user :
warning: Missing argument 2 for user_category_load(), called in .../public_html/includes/menu.inc on line 411 and defined in .../public_html/modules/user/user.module on line 1155.
warning: Missing argument 3 for user_category_load(), called in .../public_html/includes/menu.inc on line 411 and defined in .../public_html/modules/user/user.module on line 1155.
However, I don't even have account profile installed at all!
I DO have content profile 6.x-1.0 and profile 6.22 installed, and am NOT using the 'me' module.
So, perhaps this problem lies elsewhere.
Comment #16
mattcasey commentedI just noticed that when ' Redirect on User Edit page' is checked, it redirects to the wrong URL. It uses "user/X/edit/profile" when the correct path to my content profile is "user/X/profile/profile" If I put that path in instead, it works.
[UPDATE]
I manually updated the hook_form_alter in #11 and it fixed the issue for me. If you don't want to hack the module, one could also try setting the Content Profile to only "appear as a tab underneath Profile" from the content profile settings for the content type, because then it uses the path: edit/profile instead of profile/profile
Comment #17
PixelClever commentedI fixed mine by changing a few lines starting at line 44:
Comment #18
mistri commentedHey snowmountain,
Did you finally get around this error in the end? I have exactly the same error (lines 411 and 1155 in menu.inc and user.module) - they refer to
$return = $function($value); and
function user_category_load($uid, &$map, $index) respectively.
I have tried going through all the modules I have installed and i cannot see which one it is being affected by. I have logintoboggan module with Front_page and that is fine. I disabled Content Profile but am still getting the error.
Thanks for getting back soon!
Comment #19
iRex commentedsubscribing
Comment #20
snowmountain commentedSorry, I've been pretty busy lately. No progress yet.
Comment #21
jippie1948 commentedapplied #17, still same problem... :-(
Comment #22
frosty29 commentedThanks #16 - that led to the answer which solves my problem.
I didn't see #17 before I did my own clunky fix in account_profile.module (about line 42):
I can keep the account profile settings I needed and all my errors have apparently now gone.
Comment #23
jippie1948 commentedSorry, it did not work for me.
Comment #24
wm753v commentedI installed Password Policy module, and it happened. As soon as I uninstalled it, the errors disappeared. I don't know how to install this module without getting the errors.
Comment #25
arski commentedsub
Comment #26
iRex commentedI had this issue on several sites that I built, and each time, like #24, I solved it by remove the Password Policy module. I think that's where the problem lies.
Comment #27
gbirch commentedI had this problem in a site that did NOT have password policy installed.
The fix in #17 seems to be the right approach, but only works if the currently logged in user is editing his or her own profile, NOT if the admin is trying to do so.
Alternative fix that seems to work for BOTH users and admins is to edit
function account_profile_form_alter in account_profile.module as follows:
Comment #28
queryblitz commentedThanks gbirch! That worked after clearing the cache. Big help.
Comment #29
kenorb commentedClosing as per Drupal 6 end-of-life. Unless somebody can provide a clean patch.