By melchior on
hi guys,
I'm searching for a long time a solution that enables me to strip down data fields like...
- Authoring information
- publishing options
- Menu settings
... for example
I want to fill this fields only programmaticly by my module.
the user won't need the option to fill this by himself.
currently I found module like formfilter or filterbynode,
but at all those didn't satisfy my needs
thx for comments,
I'm really needin them!! ;)
melchior
Comments
These fieldsets aren't
These fieldsets aren't visible to users without the 'Administer nodes' permission. Would it solve your problem if you put your users in a role without this permission, or do you need finer grained control?
You could unset the specific fieldsets you don't want in the form array with hook_form_alter
The suggestion to unset the
The suggestion to unset the fields is good, but sometimes unsetting them will cause the next module that fires to get a null value for that. Suppose you have a module that wants to set published = 1 then I would just use #type =>'hidden' for these elements so they are still in the $form object but are not confusing the user. Then again, this is not 100% secure as the person could set the values in post, but as the previous poster said, they should not have admin nodes permission then if that is a factor.
thx!! this works like a
thx!!
this works like a charme!
I used #type =>'hidden' by hook_form_alter
best regards,
melchior