E
E
EvgMul2017-03-14 09:59:02
Yii
EvgMul, 2017-03-14 09:59:02

How to call renderAjax() or action from another action or view?

Hello. I have the following problem.
When the button is clicked, a modular window appears, which is generated through the action, and inside it is renderAjax ().
There is a certain condition under which this window should pop up immediately, and not after clicking.
I can not figure out how to do this and in what place of the application. Please tell me the solution to this problem.
Thanks in advance to all who respond.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
M
Maxim Timofeev, 2017-03-14
@EvgMul

module window that is generated via action
modular or still modal? But to hell with him. Through ajax action, it is worth generating content for the modal window, and not the window itself. You cling to the "show.bs.modal" event and send ajax, get it, insert it into the body of the modal.
So far, what is the problem? You do not know how to call a modal without a click? Then like this:
Here everything is detailed and yii obviously has nothing to do with it:
getbootstrap.com/javascript/#modals-methods

S
Shinso, 2017-12-25
@rafamont

Something I can't understand with what exactly you have problems there is a block li

.bars li {
    position: relative;
    margin-bottom: 60px;
    background: #ccc;
    height: 42px;
    border-radius: 3px;
}

There is a span block absolutely positioned relative to it
.bar-expand {
    position: absolute;
    left: 0;
    top: 0;
    margin: 0;
    padding-right: 24px;
    background: #313131;
    display: inline-block;
    height: 42px;
    line-height: 42px;
    border-radius: 3px 0 0 3px;
}
.photoshop {
    width: 60%;
    -moz-animation: photoshop 2s ease;
    -webkit-animation: photoshop 2s ease;
}

What is the difficulty then?

T
trushka, 2017-12-25
@trushka

you can still stir it up with the help of the <progress> element , but there you have to dance with a tambourine to colorize this thing cross-browser) There are links to css pseudo-elements for styling for different browser engines at the bottom of the article..

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question