When setting permissions for anonymous users to «create full projects», «administer projects», and even checking ALL permissions exept «administer nodes» — they still can't create project

The only way to allow them create projects — to select «administer nodes», but then they will be able to create any type of content, not only project.

I suppose it's a bug becouse i downloaded drupal, project and project issue modules and recreated the problem.

CommentFileSizeAuthor
#6 1391994-6.anonymous-project-creation.patch824 bytesdww
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dww’s picture

Category: bug » support
Priority: Major » Normal
Status: Active » Postponed (maintainer needs more info)

It's not clear why you'd want to allow anonymous users to create projects. They'll never be able to come back to edit them, maintain anything about them, etc. Why do you want this? Seems like configuring a site to allow anonymous project creation is asking for trouble, so yeah, the module doesn't really let you do that. I agree it's a bit of a bug that this edge-case is hard-coded and not just controlled by the appropriate permissions, but it's certainly not a major bug.

Before anyone "fixes" this, can you explain more about your setup and why you even want this?

Cheers,
-Derek

4abv’s picture

Derek, It's connected with the specificity of my site. I want to turn project page to technical task. Also I want to use «inline registration» module that could solve problems, you pointed on.
I would be very obliged if someone tells me how to let anonymous users do it even with the help of hardcoding. All my manipulations with project.module and even node.module didn't led to anything… (I am amateur in programming)

Andrew. Happy New Year!

4abv’s picture

Ok, i solved the problem.

In the node.module after:

  // Let authors view their own nodes.
  if ($op == 'view' && $account->uid == $node->uid && $account->uid != 0) {
    return TRUE;
  }

Changed :
return FALSE;
To
return TRUE;

4abv’s picture

Or, I think, even better — to add
before:
return FALSE;
this:

  if ($op == '') {
    return TRUE;
  }

Do it at your own peril :-)

dww’s picture

Assigned: 4abv » dww
Category: support » task
Status: Postponed (maintainer needs more info) » Needs review
FileSize
824 bytes

Uhh, no. ;) You don't want to mess with node.module (ever). That's known as "hacking core" and is generally a terrible idea. I'm sure if you google for "drupal hack core" you'll find some useful articles about it.

Instead, you want to hack the project.module. ;) In particular, see the attached patch.

dww’s picture

(Heh, yeah, the first hit is http://drupal.org/best-practices/do-not-hack-core which covers it pretty well).

Status: Needs review » Needs work

The last submitted patch, 1391994-6.anonymous-project-creation.patch, failed testing.

dww’s picture

Bah. Ignore those test failures, they're a false negative from another bug. Unrelated to the change here.

drumm’s picture

Version: 6.x-1.0-alpha5 » 6.x-1.x-dev
Issue summary: View changes
apaderno’s picture

Version: 6.x-1.x-dev » 7.x-2.x-dev

The Drupal 6 branch is not supported anymore. If there are changes to be done, those should go to the Drupal 7 branch.