H
H
hdtor2016-03-14 19:06:21
PHP
hdtor, 2016-03-14 19:06:21

Is it safe to do so?

Hello.
Is it safe to connect the core site system like this? I mean ../

<?php

include("../include/core.php");

//тут пошел код

?>

I read somewhere that it's not very safe to connect like that?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
Alexey Skobkin, 2016-03-14
@skobkin

And what, exactly, is the problem? And what alternatives do you see?
Or are you talking about include vs require vs include_once vs require_once?

A
Andrey, 2016-03-19
@AndryG

It's dangerous like this:

<?php

include($_GET['lang']."/phrases.php");

//тут пошел код

?>

A
Andrey, 2016-03-15
@GhOsT_MZ

Weird. And what is the danger of such a connection?
In fact, there are three connection options:
The first option is generally useless. There are not many options left.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question