question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How i can get access to swal2 modal content?

See original GitHub issue

Inside callbacks, without direct $('.swal2-content')? 😄

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:1
  • Comments:14 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
projct1commented, Jan 14, 2017

@limonte Yea, but i need content only, without uneccesary wrapper. I written $('.swal2-content') only for find my form inside swal. My final code was $('.swal2-content form') =)

0reactions
projct1commented, Jan 14, 2017

Here my case:

$.get(e.target, function(response) {
                    swal({
                        html: response,
                        /* some params */
                    }).then(() => {
                        let form = $(swal.getContent().children);

                        $.post(form[0].action, form.serialize());
                    });
                });
Read more comments on GitHub >

github_iconTop Results From Across the Web

SweetAlert Prompt issue in bootstrap modal - Stack Overflow
I have been trying for more than two days to run SweetAlert prompt in a modal bootstrap without success, the input is not...
Read more >
SweetAlert2 - a beautiful, responsive, customizable and ...
A modal window with a long content inside: Try me! Swal.fire({ imageUrl: 'https://placeholder.pics/svg ...
Read more >
Creating Pretty Popup Messages Using SweetAlert2 - Code
All you have to do is call the Swal.fire() function. ... You can get the title, content, and image of a modal using...
Read more >
JavaScript · Bootstrap
Varying modal content based on trigger button. Have a bunch of buttons that all trigger the same modal, just with slightly different contents?...
Read more >
@sweetalert2/ngx-sweetalert2 - npm
The directive will replace certain parts of the modal (aka. swal targets) with embedded Angular views. This allows you to have data binding, ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found