• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Problème d'autorisation

Contributor ,
Nov 28, 2023 Nov 28, 2023

Copy link to clipboard

Copied

Good morning,
In order to be able to put an icon, I test if the file exists!
 

 

<CFIF fileExists ("#DIRV#")> <A href="../../Admin/_ebooks/Libre_Video.cfm"><img src="../../Admin/_Pictures/Video.gif" width="30" height="30" title ="Presentation Video" /></A> </CFIF>

 

But since I'm in a loop, I'm going to get negative answers! Here is the error message:

Security: The requested template has been denied access to /SoLivres/_Ouvrages/APED/Auteurs/IRLES/UNE_ENFANCE_PIEDS-NOIRS/Videos/UNE_ENFANCE_PIEDS-NOIRS.mp4.

 

The following is the internal exception message: access denied ("java.io.FilePermission" "/SoLivres/_Ouvrages/APED/Auteurs/IRLES/UNE_ENFANCE_PIEDS-NOIRS/Videos/UNE_ENFANCE_PIEDS-NOIRS.mp4" "read")

Thank you for your help.

 

Bonjour,

Afin de pouvoir mettre une icone, je teste si le fichier existe !

 

<CFIF fileExists ("#DIRV#")>
<A href="../../Admin/_ebooks/Libre_Video.cfm"><img src="../../Admin/_Pictures/Video.gif" width="30" height="30" title="Presentation Video" /></A>
</CFIF>

 

Mais comme je suis dans une boucle, je vais avoir des réponses négatives !

Voici le message d'erreur :

Security: The requested template has been denied access to /SoLivres/_Ouvrages/APED/Auteurs/IRLES/UNE_ENFANCE_PIEDS-NOIRS/Videos/UNE_ENFANCE_PIEDS-NOIRS.mp4.

The following is the internal exception message: access denied ("java.io.FilePermission" "/SoLivres/_Ouvrages/APED/Auteurs/IRLES/UNE_ENFANCE_PIEDS-NOIRS/Videos/UNE_ENFANCE_PIEDS-NOIRS.mp4" "read")

Merci de votre aide.

Views

107

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 28, 2023 Nov 28, 2023

Copy link to clipboard

Copied

This seems like an ideal place to use CFTRY/CFCATCH:

 

<cftry>

    ... error-prone code goes here ...

   <cfcatch type="Any">

   ... safe response goes here ...

   </cfcatch>

</cftry>

 

Dave Watts, Eidolon LLC

Dave Watts, Eidolon LLC

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 03, 2024 Apr 03, 2024

Copy link to clipboard

Copied

LATEST

"/SoLivres/_Ouvrages/APED/Auteurs/IRLES/UNE_ENFANCE_PIEDS-NOIRS/Videos/UNE_ENFANCE_PIEDS-NOIRS.mp4" is a relative path. You have to replace it with the full path. That is, with the absolute path of the file on the server.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation