Borrar
Posted: Tue Jun 13, 2023 4:07 pm
<br> {{VAR(USER_ROLE)@IFEQ(Super Admin)@THEN(<a href="/delete/data/%id%">Borrar</a>)@ELSE()}} esto funciona en API data lister. Para file lister y Post lister?
Code: Select all
{{VAR(USER_ROLE)@IFEQ(Super Admin)@THEN(<a href="%delete%">Borrar</a>)@ELSE()}}
francisco wrote: ↑Tue Jun 13, 2023 9:15 pmI would recommend you to use the %delete% tag instead of the hardcoded URL, to avoid disruption to your site if the URL changes in the future.
- For File Lister: /delete/file/%id%
- For Post Lister: /delete/post/%id%
Also keep in mind that even if you are configuring the link to only be displayed to Super Admins, the userCode: Select all
{{VAR(USER_ROLE)@IFEQ(Super Admin)@THEN(<a href="%delete%">Borrar</a>)@ELSE()}}
who created/uploaded the resource can type the URL into the browser and be able to delete the resource.francisco wrote: ↑Tue Jun 13, 2023 9:15 pmI would recommend you to use the %delete% tag instead of the hardcoded URL, to avoid disruption to your site if the URL changes in the future.
- For File Lister: /delete/file/%id%
- For Post Lister: /delete/post/%id%
excelente, muchas gracias.Code: Select all
{{VAR(USER_ROLE)@IFEQ(Super Admin)@THEN(<a href="%delete%">Borrar</a>)@ELSE()}}
Also keep in mind that even if you are configuring the link to only be displayed to Super Admins, the user who created/uploaded the resource can type the URL into the browser and be able to delete the resource.