Y
Y
Yuri Shchegolikhin2018-03-15 21:01:11
PHP
Yuri Shchegolikhin, 2018-03-15 21:01:11

Code that will open a file in the same folder?

Tell me the code that will open:
from the local/integration/importFromXml.php file, the file in the same data/data.xml folder

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander, 2018-03-15
@AK-VoronM

$file = __DIR__ . "/data/data.xml";
$f = file($file);
$XML = simplexml_load_file($file);

Well, or in any other way you need)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question