M
M
mr-zherart2014-10-19 14:43:29
Yii
mr-zherart, 2014-10-19 14:43:29

How to solve Elfinder Yii connection problem?

Hello! I use the eltref extension to work with Eltre and Elfinder in the Yii admin.
Everything works great on local, but on remote hosting it gives an error "Incorrect connection to the server", that is, a 500 error
. receive an adequate response to the request.
Failed to load resource: the server responded with a status of 500 (Internal Server Error) http://mysite/assets/4db94b58/elfinder/connectors...
Just a simple request just goes to the main page.
Help, who faced. +1 to karma)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
mr-zherart, 2014-10-21
@mr-zherart

Everything was decided by gathering information and understanding that it is necessary to process scripts correctly.
The extension itself has the wrong path to connector.php. Instead (this is one of the options), you need to connect from assets, create a separate action in the controller and connect the connector in it through the class.

class ProgramController extends Controller
{

public function actions()
    {
        return array(
            'connector'=>array(
                'class'=>'application.extensions.elrtef.elfinder.connectors.php.connector',
            ),
        );
    }

...

Then in the elRTE.php file, where there is a connection to the connector, you need to write the path to the action Yii::app()->createUrl('program/connector');
Makarov's book Collection of recipes Yii 68 page helped a lot. Connecting external actions (read external scripts)

S
Sergey, 2014-10-19
Protko @Fesor

>>but Yii automatically redirects to the main page of the site.
To do this, the request for connector.php must be sent to yii by your web server.
For this to happen with the default Nginx / Apache2 configs (which are in the documentation) - there should not be such a file. If there is no such file - you have a problem with the paths

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question