Answer the question
In order to leave comments, you need to log in
Embedding admin in php MVC?
Brr, unravel, pliz ...
So I did everything according to science).
And how is the admin panel built in with such a concept? Separate "site"? Or a general concept?
So I got something like this...
mysite.ru
mysite.ru/city1
mysite.ru/cityN
mysite.ru/admin? - make this admin a separate directory (as I used to have) and write a separate kernel, controllers, etc. to it. or to build in the general heap? It’s just that then I don’t quite understand right away how to restrict access to this controller and method ... so the usual htaccess and htpasswd are in the directory and everything is clear ...
How "by science then"?)
P.s. well, in order not to produce questions .... it remains to add an auxiliary class (conditional) helper - a certain set of functions that helps in development and is used in many models - various formatting, etc. Is it strong if you connect it and inherit controllers and models from it?
Answer the question
In order to leave comments, you need to log in
.then
and they .finally
only hang handlers and no matter in what order they are called
, callback, which will hang the method .finally
, will always be called last
It's just a heavily simplified version of a promise that doesn't work like the real thing.
Here's what's going on that interests you:
if (this.onFinally) {
this.thenCbs.forEach(cb => {
data = cb(data)
})
this.onFinally()
}
Here's a great example for you: guide.yii2.org-info.by/guide-en-tutorial-advanced-...
backend - web application of the administrative part. (this is the admin panel)
common - common files for all applications. (common to all)
frontend - user's web application. (this is the site itself)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question