Skip Navigation

[Resolved] Is there a way to disable users of deleting images when editing their post form?

This support ticket is created 4 years, 6 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

Tagged: 

This topic contains 11 replies, has 2 voices.

Last updated by ricardoL-4 4 years, 6 months ago.

Assisted by: Shane.

Author
Posts
#1702841
Screenshot 2020-07-10 at 16.03.48.png

Hi guys, I've created a post form where users can edit posts. The goal is the admin have control of the images of the posts, and users are only able to edit the order of images. Can this be done?

PS: So in the picture I want to get rid of the cross and the bin icon.

Thanks!

#1703133

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Ricardo,

Thank you for getting in touch.

This would need to be hidden with some custom code or CSS, however doing this will hide icons for all users including admins.

Please let me know if you're ok with this and provide some way to access the form so that I can assist with the css for this.

Thanks,
Shane

#1703197

Hi Shane, thanks for your support, this is the code of my form. Otherwise if you want I can give you access to my website.

<div class="row">
<div class="form-group col-sm-12">
<label>Imagem de perfil</label>
[cred_field field='imagem-perfil' force_type='field' class='form-control' output='bootstrap' previewsize='thumbnail']
</div>
</div>

Thank you!

#1703213

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Ricardo,

I will need access to the website itself so that i can get the correct classes for the buttons.

I've enabled the private fields for your next response.

Thanks,
Shane

#1703233

Also I just realised that I also don't want that users can add images... I really just want them to be able to move pictures position order. is that possible too?

Thanks!

#1705285

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Ricardo,

Also I just realised that I also don't want that users can add images... I really just want them to be able to move pictures position order. is that possible too?

Are you saying that you don't want the use to be able to add any images at all ? But just to move around the images? How would the initial images get added to the form if the user isn't allowed to add any images.

Can you explain in a little more detail for me. Also I saw that you provided access but no link to the form itself on the frontend. I need an example post in order to provide the css to hide this.

Thanks,
Shane

#1705407

Hi Shane,

Ok, so my point is I want as an Admin to add images at the backend of the site or eventually thru Criar Anúncio de Massagista (ID: 2478) form, and at the frontend Editar Anúncio (ID: 870) form, I just want users to move them around. So users cannot delete or add any images... I hope it's clear now 🙂

The form name is that I want users do use is Editar Anúncio (ID: 870)

Thanks

#1705421

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Ricardo,

Will these user's be regular users ? Or users with permissions to edit the posts ?

The reason being, i would advise against allowing regular users to modify the posts on the frontend.

Secondly I've added the css to the site to remove the trash icons. However admins will be the only ones that can make changes and this will need to be done on the backend.

Thanks,
Shane

#1705603

Hi Shane,

It will be users with permissions only. The website will have costumers adds, where they can only change fixed stuff that admin puts before. So what you did is what I wanted. Just one more thing, is there a way to also hide the "add new" link, like you did with the delete images on the same form?

Thanks!

#1705605

...also, is there a way to show the pictures at the frontend horizontally, instead of vertically ?

Thanks 🙂

#1705725

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Ricardo

It will be users with permissions only. The website will have costumers adds, where they can only change fixed stuff that admin puts before. So what you did is what I wanted. Just one more thing, is there a way to also hide the "add new" link, like you did with the delete images on the same form?

I would recommend using a different form, where one link appears for a specific set user roles and the other for another set of user roles.

...also, is there a way to show the pictures at the frontend horizontally, instead of vertically ?

For this it is not possible to achieve.

Thanks,
Shane

#1708533

My issue is resolved now. Thank you!