Form Access & User Content Access

hi,

this is my first post on elgg (",)

i would like to only give my friends the ability to create content using my forms, but the content generated by the forms will be accessible to public.

i tried setting access in form to friends and added the access pulldown as a form field, and setting it to public. but this doesn't seem to work as i expected.

is it possible to set the form access to friends, and content access to public?

noob

  • Yes.

    In short - make the form viewable by your friends only.

    Then when creating the form, add an access control box with the default value 2 (ACCESS_PUBLIC).

    You can even make the access control box visible only to admins by making the field admin-only.

  • Thanks, Kevin, for the quick response!

    I can't seem to get that to work. In my river dashboard, I can see that I have added content to my form. But when I logged in as another user, I see that I added content to "".

    And when I click on the content link, I get the following error message.

    Fatal error: Call to a member function getOwner() on a non-object in /public_html/community/mod/form/start.php  on line 75

    It'll only work if I set the the form viewable to logged-in users.

  • I've looked at the code and cannot see immediately why what I wrote would not work.

    I'll try to look at this next week and see if I can reproduce the problem.

  • alright, i suppose at the moment, i'll have to hide the "Add Content" option for non-admin users. i hope i can figure that out myself, but it'll be great if you can give me some pointers. cheers!

  • oh, and by the way, i'm using elgg release 1.7.1, version 2010040201 (in case you need it for debug)

  • i figured it's better if i set the content access to private by default, and the field to be edited by admin only.

  • i've to set content access to public, in order for the uploaded images to appear correctly. (".)

  • Hi Kevin,

    Have you managed to take a look at this problem? Hoping for a work-around or better yet a fix. Thanks!

  • Sorry Ed,

    I've looked at this again and my trick would work if the access for the form was less restrictive than the access for the content, but not the other way round.

    The problem is that the Elgg access system is preventing your users from accessing the form description, which is necessary to display the form content as well as the form itself.

    I have no work around for that.

Form and related plugins

Form and related plugins

User-generated content, flexible user and group profiles, registration forms, custom file forms