BrownieCoffee
1 month ago

Display modal for specific user

Posted 1 month ago by BrownieCoffee

Hi there.

I have js file and blade.php file

I would like to display modal to his user. Actually I have this logic bellow.

   displayUserBanModal: function(){
            var banModalBtn = $('.showUserBanModal');

            var banModal = $('.modal--ban');

            banModalBtn.on('click', function(e){
                e.preventDefault();
                $(this).next(banModal).toggleClass('is-active');
            });
        }

But I would like to use the id of my buttons instead of this logic who seems to be limited in future.

You you have any idea ? Thank's in advance

S.U.+

Please sign in or create an account to participate in this conversation.