I'm not entirely sure why but suddenly I can't add new users as admin (user 1), I've also tried creating a role with all permissions enabled and still can't add a new user. I keep the "Access Denied" page. I've tried uninstalling modules, tweaking permissions etc but still no success.

Any help would be appreciated.

Thanks.

CommentFileSizeAuthor
#10 abc.jpg2.17 MBvin247

Comments

dpearcefl’s picture

Any errors in the Drupal log or your webserver's log? Or database log?

vin247’s picture

No error logs, I've also enabled PHP error reporting but I get nothing.

Looking at drupal's report I see the following:

Type access denied
Date Wednesday, June 15, 2011 - 09:19
User admin
Location http://www.mysite.com/user/register?destination=admin%2Fuser%2Fuser%2Fcr...
Referrer http://www.mysite.com/admin/user/user/create
Message user/register
Severity warning
Hostname 00.000.000.000
Operations

dpearcefl’s picture

Random thoughts:

  1. Have you done an analyze on your database to make sure it isn't corrupted?
  2. Do you have Drush on this system? it can add users and sometimes generates more meaningful error messages.
  3. Have you added or changed anything recently on the site?
  4. Have database permissions changed at all?
  5. Try disabling a few modules at a time until you are down to core modules.
  6. Have you hacked cord or contrib modules? Do you have an custom modules running?
  7. What database are you using?
  8. What OS?
  9. What webserver?
vin247’s picture

The most recent module I installed was the ERP module as it rebuilt permissions, which I suspect may be the problem but I can't be certain. Anonymous users can register for a user account with no problem however so I'm quite baffled why I can't as user 1/admin.

Will be looking into those points you've made.

dpearcefl’s picture

Have you rebuilt permissions yourself? /admin/content/node-settings

dpearcefl’s picture

Have you disabled that module, rebuilt permissions and then retested?

cptlonestar’s picture

I thought I had the same problem since there wasn't a column listing admin permissions. It looked different in the O'Reilly Using Drupal book than what is now being used in version 6x.

I realized at the very bottom of the permissions page there are check boxes under "user module" that allow you to check whether or not a user has admin permissions over the entire site. Perhaps this is the issue? Or are you missing this specific user module permissions section?

vin247’s picture

@dpearceMN yep, I've tried that and unfortunately no success

@Matthew33 I do have those options available in permissions, still no luck yet though

dpearcefl’s picture

Can you screenshot your permissions page and attach it?

vin247’s picture

StatusFileSize
new2.17 MB

screenshot of permissions page, sorry it's quite large, just used screengrabber in firefox

dpearcefl’s picture

I would disable all non-core modules, rebuild permissions and try again. I know you say you've already done this, but try again.

Anything else not work on the site? Have you tried to use Drush to create a user? You might get a better error message.

Your are on the latest 6.x Drupal? Have you hacked Drupal at all?

What about using the Devel module and turning on the redirection debugging?

vin247’s picture

Tried enabling/disabling modules again but still no luck, not getting much from the devel module.

Drupal version = 6.19, not hacked drupal.

How do I create a new user using Drush?

Cheers

dpearcefl’s picture

Please try the most recent version of Drupal (6.22 I believe) as this problem may have been fixed. Obviously in a test environment.

If you have drush installed: drush help user-create

ilvdrupal’s picture

I am also having same problem after migrating site to another server. (from windows to linux) . When I submit the use create form, it does not say access denied but no action performed. users list is displayed directly and the new user is not added. Anonymous users can register through registration form. Please let me know if you could solve this. Thanks,

ilvdrupal’s picture

My issue fixed.

After checking for long time, realized submit button value was changed. Reverting it back to original 'create new account' helped me fix this issue.

dpearcefl’s picture

Status: Active » Fixed
dpearcefl’s picture

Status: Fixed » Active

Waiting to hear from the OP (vin247).

vin247’s picture

It works fine on a fresh install of both the version I'm using for the project and .22, not tried drush method yet, however the status of the project has stalled so you can close this thread if you want, however I'd like to know how ilvdrupal managed to revert the value of the submit button???

dpearcefl’s picture

Status: Active » Fixed
ilvdrupal’s picture

@vin247 : Submit button value(from 'create new account' to 'submit') was changed by previous developer. I just removed those changes.

dharani87’s picture

@ilvdrupal
where i have to modify those changes( submit to create new account)
I checked it in user.module
where it still shows the 'create new account' text in submit value but my output(user/user/create page) shows the button value 'submit'..
Plz help me!!!

myregistration’s picture

subscribe

ilvdrupal’s picture

@dharani87 : sorry for late reply. then must be some custom module through form_alter hook. If you still cannot find, i suggest irc. easier to help.

Jerimee’s picture

Had the same problem. Restoring the #value of the user_register submit button to "create new account" per

http://drupal.org/node/1188976#comment-4733292

fixed it.

I had a custom module with form_alter hook that altered the user registration form.

Jerimee’s picture

This comment is off topic (sorry!).

The stringoverrides modules successfully changes the text of the user_register submit button: http://drupal.org/project/stringoverrides

cjd400’s picture

Found one module that causes it at least - Simplenews Scheduler seems to cause the problem. I have let the writer know here http://drupal.org/node/1251322 - glad if this helps anyone - does anyone else know of any other modules that cause this?

Cheers

CJD400

cjd400’s picture

btw the stringoverides did not solve this - it seems the code (whatever is causing this) within Simplenews Scheduler overwrote it etc.

CJ

dgtlmoon’s picture

comment #26 , I can't seem to reproduce this when I enabled the simplenews scheduler module

dgtlmoon’s picture

Can you disable javascript in your browser and see if it works? that would help to rule out any jQuery

dgtlmoon’s picture

Although I have no been able to reproduce this, I have refined the jQuery selector so it only applies to the newsletter form.

http://drupalcode.org/project/simplenews_scheduler.git/commit/8f8569b

Try the current dev release and let me know if it helps! (Don't forget to flush your cache/compressed js files)

vin247’s picture

back on the project again so if anyone has any other ideas on how to solve this problem that would be great!

I've tried creating a user with drush and it works fine. Obviously this isn't practical for when I had the site over to the client to manage so would like to get it sorted.

dgtlmoon’s picture

@vin247 Can you reproduce the problem through the browser?

vin247’s picture

hmm i've only just had time to test in on the browser again and funnily enough it works fine now, maybe the drush method gave it a kick up the backside, I don't know, but all is well for now.

Thanks to everyone for the help!

Automatically closed -- issue fixed for 2 weeks with no activity.