By teri@bglog.net on
Hello!
I have a multiblogging site and I wish to make a role, that can't promote posts in node. The users with roles "Unpublish" will have content in their blogs, but this content will be not visible in front page (/node).
Please, help with solution to this problem
Comments
You need a module...
I'm assuming you want to allow these users to promote the entries immediately not thru moderation or anything like that. Unfortunately the promotion check box is in the admin block of the node, and therfore only available to roles with "administer nodes" permission - this is an all or nothing kinda solution as administer nodes gives them god like powers over every node, not just their own.
To make this permission more granular, you will need a module. At a high level you need to implement the following:
1) hook_access : this will let you set the permission you want for the role you want, maybe something like "promote blog to front page"
2) hook_nodeapi : check for type 'blog', the "promote blog..." permission and make sure the $user->uid is the $node->uid (??maybe not this last check??) then insert your promote/ publish checkbox into the node form. The checkbox should be tied to the same variable that the admin version is tied to - I think it's $node->promote
Check drupaldocs.org for an explanation of how these functions work.
If I had more time I would put this together myself - sorry ;) - but someone should be able to do this within 30 minutes or so...
Thanks!
Thanks for your answer! :)
This is exactly what I want. But I want to select users with limited rights, becouse in my blog site I have quality users, and ...not so good members.
I want to make posible the storyes of good users to show in front page (this is node for me), but users that write bad things to write what they want only in their blogs. These "bad users" are not so bad to ban them, but they write in latin characters in bulgarian blog and this is not welcome. They must write in cyrrilic, when they post bulgarian story. But the youngest members think the latin is "cool" and I want to let them write their blogs, but hide them from general public of the site :)
Sorry for my english, I need practice :)