Hello Felix,
let's take it from the top:
Why? Do you get an error message that the file was not found? Or what makes you believe that the include doesn't work?
This is my test:
index.php:
I get the output, so the include seems to work.
But, maybe you mean that your upload does not work?
Notice right at the start: The Upload Processor requires a login, the session 'loggedin' must be set for the upload to succeed.
Also note that an upload without registration is an extremely dangerous thing. I would never allow it, instead I would use a service (API) specialized for it, but that' s your stuff...
Ok, let's test it.
Same dir structure:
index.php: https://gist.github.com/bigin/abbebba6ae...ebecb2259a
Everything works.
FYI: The upload is using Ajax, you can see the errors in your log file under: /framework/data/logs/imlog_2020*.txt
The imanager.php file is responsible for this. This file is always located one layer above the imanager/ folder ;-)
let's take it from the top:
(2020-08-24, 05:51:41)Felix Wrote: So when I have the backend.php inside: /test/backend.php
in backend.php I adapt include 'framework/imanager.php'; to => include '../framework/imanager.php';
But this doesn't seem to work correctly.
Why? Do you get an error message that the file was not found? Or what makes you believe that the include doesn't work?
This is my test:
Code:
root/
application/
index.php
framework/
imanager.php
...
index.php:
PHP Code:
<?php
use Imanager\Util;
include '../framework/imanager.php';
Util::preformat($imanager->config);
exit;
I get the output, so the include seems to work.
But, maybe you mean that your upload does not work?
Notice right at the start: The Upload Processor requires a login, the session 'loggedin' must be set for the upload to succeed.
Also note that an upload without registration is an extremely dangerous thing. I would never allow it, instead I would use a service (API) specialized for it, but that' s your stuff...
Ok, let's test it.
Same dir structure:
Code:
root/
application/
index.php
framework/
imanager.php
...
index.php: https://gist.github.com/bigin/abbebba6ae...ebecb2259a
Everything works.
FYI: The upload is using Ajax, you can see the errors in your log file under: /framework/data/logs/imlog_2020*.txt
(2020-08-24, 16:07:20)Felix Wrote: Despite that it is working now locally, how does it find the location of the framework folder ?
include 'framework/imanager.php'; this is a relative path,
but the folder framework does not exist relative to the backend.php template file, it is in the root of GS.
The imanager.php file is responsible for this. This file is always located one layer above the imanager/ folder ;-)