Menu link to display all users media

4 years 2 months ago #316241 by activha
Menu link to display all users media was created by activha
Hello

We would like to build a page displaying all users media that are public, whether it is pictures or videos.

What would be the best solution for this ? an auto action ?

Thanks

Please Log in to join the conversation.

4 years 2 months ago - 4 years 2 months ago #316242 by krileon
Replied by krileon on topic Menu link to display all users media
Media from where? If CB Gallery simply create a Joomla menu item to CB Gallery plugin and set the Asset parameter to "all" for all CB Gallery entries. If you specifically only want profile gallery entries you can use the profile.% asset. I assume by public you mean via CB Privacy, which should still be respected when outputting all gallery entries like that.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

4 years 2 months ago #316243 by activha
Replied by activha on topic Menu link to display all users media
Yes that's it, only gallery items defined as public by privacy plugin to start with. I'll try with the gallery plugin menu.

Next we would like any registered user to be able to select an item shown by this menu and have this item display on its own profile.

I was thinking of a new cb field in which the chosen asset number would be selected. Is it possible to do ?

Can we build a button like the like button which would set the item reference to the cb field ? Could we do it by auto action?

I'd be glad to have your ideas

Please Log in to join the conversation.

4 years 2 months ago #316244 by krileon
Replied by krileon on topic Menu link to display all users media

Next we would like any registered user to be able to select an item shown by this menu and have this item display on its own profile.

I was thinking of a new cb field in which the chosen asset number would be selected. Is it possible to do ?

Can we build a button like the like button which would set the item reference to the cb field ? Could we do it by auto action?

Entries do not have an Asset unique per entry. So you can't just add 1 media entry from 1 gallery to another without flat out copying it. So the only way to do that would be to take the gallery entry they want displayed on their profile, make a copy of it, and change its asset to match their profile. I guess the best way to go about doing that is a Query auto action and just directly makes a copy using an INSERT SELECT query and modify the asset in the SELECT. As for adding the button you'd have to use a Code action to output the HTML; see the like system action for example on how to render the button in the modal window.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

4 years 2 months ago #316245 by activha
Replied by activha on topic Menu link to display all users media
Could we buy a support ticket and ask you to write all this for us ?

Please Log in to join the conversation.

4 years 2 months ago #316252 by krileon
Replied by krileon on topic Menu link to display all users media
No, we do not provide such a service. The below example should get you started.

INSERT INTO `#__comprofiler_plugin_gallery_items` ( `user_id`, `asset`, `type`, `value`, `file`, `folder`, `title`, `description`, `thumbnail`, `published`, `date`, `params` ) SELECT `user_id`, 'profile.[user_id]', `type`, `value`, `file`, `folder`, `title`, `description`, `thumbnail`, `published`, `date`, `params` FROM `#__comprofiler_plugin_gallery_items` WHERE `id` = MEDIA_ID_HERE

The above should make a copy of someone elses media to your profile gallery based off the ID of the media, which you'd need to supply to MEDIA_ID_HERE.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.309 seconds

Facebook Twitter LinkedIn