Keyword

Allow User to edit certain item (automated)

  • john
  • john's Avatar Topic Author
  • Offline
  • Junior Member
More
10 years 9 months ago #116796 by john
Under one K2 category, I plan on having hundreds and hundreds of items. Any way to set parameters to allow one user edit a chosen item by the admin?

Im letting businesses post their ad on my website, they should be able to edit only that item and not any others. How can I allow this?

Please Log in or Create an account to join the conversation.

More
10 years 9 months ago - 10 years 9 months ago #116797 by Johan
Yea, you just assign the k2 item to the user and allow front-end editing of own items.

Note: I thought you said, you want them to be able to only edit the AD. So I wrote this.

For your second question. How do you plan on running the ads? There is a component for Joomla called ad agency that can help you with this. However if that ad is gonna be specific on certain pages and not random from advertisers then you need to tell me how you plan on getting the ad from them. Upload? Where? How?Email it to you? Will it change? Will there be durations involved in the Ad? What type of ad? etc.

More importantly, where do you want to display the ad? If you want to add it from a k2 item. You can either create an exta field as an image/text/ etc whatever the type of ad is. And show it wheverever in the k2 item if that specific item if thats what you wanna do. You can use a custom itemform.php to allow only editing of that specific field using something like

<?php $user =& JFactory::getUser()

and if ($user->xxx) ??

<?php echo $extrafields[the ID of the extra field];?>

Please Log in or Create an account to join the conversation.

  • john
  • john's Avatar Topic Author
  • Offline
  • Junior Member
More
10 years 9 months ago - 10 years 9 months ago #116798 by john
I cant find out how to allow a user to edit that item, its just giving me the option to edit a category, and I do not want to create thousands of categories.
I plan on running the ads by breezingforms. User submits a form and then theyre able to edit.
Either that or theyre allowed to create only one K2 item and submit. The item should be place in that category automatically.

Please Log in or Create an account to join the conversation.

More
10 years 9 months ago #116799 by Johan
Open the iten. On the right sidebar assign the user as an author.

Please Log in or Create an account to join the conversation.

  • john
  • john's Avatar Topic Author
  • Offline
  • Junior Member
More
10 years 9 months ago #116800 by john
Cant seem to find this "assign the user as an author" See image
Attachments:

Please Log in or Create an account to join the conversation.

More
10 years 9 months ago #116801 by Johan
The author is Sean now, next to it is a change button.

Please Log in or Create an account to join the conversation.

  • john
  • john's Avatar Topic Author
  • Offline
  • Junior Member
More
10 years 9 months ago #116802 by john
I thought the author was just showing who made the item, but I switched it back to the original user and it worked! thanks. Reason I overlooked was because I was logged in as sean and went to the same item and wasnt able to edit it (forgetting I didnt assign the k2 user to the k2 user group) so I figured the author didnt mean anything. Thanks!

Please Log in or Create an account to join the conversation.

  • john
  • john's Avatar Topic Author
  • Offline
  • Junior Member
More
10 years 9 months ago #116803 by john
And now I have another problem if you could help me out... checkboxes dont seem to work. Nor do the radio buttons and checkboxes on breezingforms. How can I fix this?
Attachments:

Please Log in or Create an account to join the conversation.

More
10 years 9 months ago #116804 by Johan
I think you should ask in the breezingforms forum.

But it would be helpful if you elaborated on the issue there.

Regards,
Johan

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum