Error in file search with define

1

I get this error

!/usr/bin/php Failed to open ../gestionweb/includes/afip/certificado.crt

But the file does exist, with the other files nothing happens:

This is the instruction:

define ("CERT", "../gestionweb/includes/afip/certificado.crt");  

In other words, it does not happen, but I do not know what that error means.

    
asked by Caruso 19.09.2018 в 15:12
source

1 answer

1

The problem is that you have defined a relative path. Including the same file in a different folder will bring you problems. You can fix it by normalizing the file path in absolute :

define("CERT", dirname(dirname(__FILE__))."/afip/certificado.crt"); 
    
answered by 19.09.2018 / 15:20
source