A
A
andrew_goldsmith2016-09-03 20:59:19
PHP
andrew_goldsmith, 2016-09-03 20:59:19

Modx add-on creation, an error occurs, how to solve?

Good evening everyone.
I'm making an addon for modx revolution.
The task is simple, implement the addition of data through the form by guests, and confirm / edit them in the admin panel, etc.
I searched a lot, but I found this in the Russian-language spaces. Here
, at the stage of changing the home.class.php file (for working with ajax Manager)
, an error occurs on the add-on page in the admin panel
df03f0bd6391490c895024772d56949e.png
, how to resolve it .. already worn out ... I tried everything from scratch 7 times do as instructed, the error is not gone.
who will tell?
Maybe someone will throw another resource-instruction for creating an add-on?
Or what to dig, it seems, something is not connected ...
The error was solved by changing the home.class.php file, it
should be like this:

public function loadCustomCssJs() {
        $this->addJavascript($this->Reviews->config['jsUrl'] . 'mgr/misc/utils.js');
        $this->addJavascript($this->Reviews->config['jsUrl'] . 'mgr/misc/combo.js');
        $this->addJavascript($this->Reviews->config['jsUrl'] . 'mgr/widgets/items.windows.js');
        $this->addJavascript($this->Reviews->config['jsUrl'] . 'mgr/widgets/items.grid.js');
        $this->addJavascript($this->Reviews->config['jsUrl'] . 'mgr/widgets/home.panel.js');
        $this->addJavascript($this->Reviews->config['jsUrl'] . 'mgr/sections/home.js');
        $this->addHtml('<script type="text/javascript">
        Ext.onReady(function() {
            MODx.load({ xtype: "reviews-page-home"});
        });
        </script>');
    }

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dima, 2016-09-08
@andrew_goldsmith

I think the article will help you - webhow.ru/modx-revolution/modxadd/modx-revolution-...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question