When I use Form Advanced plugins on a regular page it works fine. But if I want to create a modal form with input fields like (date, select2) then they don't work same as expected.
I think there must be some z-index issues that i'm missing. Anyways please help me on this issue.
In modals you should initialize form fields that are custom implementation for example, when you open the modal, you should initialize the plugin here is an example:
jQuery('#modal-1').modal('show', function() {
// Do the initialization stuff
});
My team mate (Arlind) can help you with this question, but he is not in the office until 17 June. When Arlind comes back, just reply to this thread and you will make sure he will see your comment.
We have very limited time of support so I am not able to provide special support over Skype. We can manage to solve these issues one by one by presenting me the page with the issue, also FTP access can help me to put the code and try fixing the problem.
So basically, prepare pages that have issues and paste the page URL here and describe the problems so I will try to give you proper solution. If that is something inside the theme support scope.
I will answer to your questions briefly to give you information how to fix several issues:
1. Its weird why is that shown, are you adding another validation on that form? Because when investigated, our theme recognizes these inputs as required only:
If you are calling $( ".form" ).validate( ... ) on another instance, then you should remove the "validate" class in the form because our theme automatically adds validation events.
2. Just like date picker, select 2 should be initialized like I shown you before:
3. On modals everything needs to be reinitialized, the DOM is freshly added to the document, so to validate the fields you must call $form.validate( {} ); and pass the options which fields to validate.
4. I have tested form wizard with data tables by enqueueing form wizard before data table:
5. In your site something is preventing jQuery Tooltip from bootstrap to be initialized. Please check your libraries to see which one is causing this issue, I have tested and in our site works:
bootstrap.js includes support for tooltips, you may change the order of bootstrap.js file, because I have tested to re-include it and the tooltips should work fine:
Uncaught TypeError: $(...).datepicker is not a function
at Object.success (ac:455)
at j (jquery-1.11.3.min.js:2)
at Object.fireWith [as resolveWith] (jquery-1.11.3.min.js:2)
at x (jquery-1.11.3.min.js:5)
at XMLHttpRequest.b (jquery-1.11.3.min.js:5)
When I use Form Advanced plugins on a regular page it works fine. But if I want to create a modal form with input fields like (date, select2) then they don't work same as expected.
I think there must be some z-index issues that i'm missing. Anyways please help me on this issue.
Thanks in advanced
YEARS
Hi Years,
In modals you should initialize form fields that are custom implementation for example, when you open the modal, you should initialize the plugin here is an example:
I hope this helps you.Please help me more on that?
I've this modal and the date is not working. In fact many of advanced plugins doesn't work.
Hi yearstech,
My team mate (Arlind) can help you with this question, but he is not in the office until 17 June. When Arlind comes back, just reply to this thread and you will make sure he will see your comment.
Thanks for your understanding!
Can I get the reply?
Hi Yasin,
Can you please give me access to that page so I can check how that can be implemented?
http://xquad.i3explore.com/demo/dept
Is someone there?
I've asked for support and hanging for almost 10 long days.
How could I develop one app if it takes so much time to solve one problem?
[ There other problems in queue. It would be great if you can help me via skype or hangouts!!! ]
Hi Yasin,
Please add the following Custom CSS in your CSS file:
And then, when generating modal content, after you append it, you can initialize it:
(view large image)
So basically to initialize the date picker in modal execute this code (after inserting HTML):
Here is the video that shows how it works explicitly:
https://d.pr/v/yMdTOc
Please note that custom implementation of code is not covered by the support, only issues like z-index issues and something that doesn't work.
You have to figure out by yourself how to initialize plugins after AJAX actions.
Dear Yasin,
We have very limited time of support so I am not able to provide special support over Skype. We can manage to solve these issues one by one by presenting me the page with the issue, also FTP access can help me to put the code and try fixing the problem.
So basically, prepare pages that have issues and paste the page URL here and describe the problems so I will try to give you proper solution. If that is something inside the theme support scope.
Hi Yasin,
I will answer to your questions briefly to give you information how to fix several issues:
1. Its weird why is that shown, are you adding another validation on that form? Because when investigated, our theme recognizes these inputs as required only:
(view large image)
If you are calling $( ".form" ).validate( ... ) on another instance, then you should remove the "validate" class in the form because our theme automatically adds validation events.
2. Just like date picker, select 2 should be initialized like I shown you before:
(view large image)
But in this case with this method:
3. On modals everything needs to be reinitialized, the DOM is freshly added to the document, so to validate the fields you must call $form.validate( {} ); and pass the options which fields to validate.
4. I have tested form wizard with data tables by enqueueing form wizard before data table:
(view large image)
And it is working:
https://d.pr/v/Xx79Kk
5. In your site something is preventing jQuery Tooltip from bootstrap to be initialized. Please check your libraries to see which one is causing this issue, I have tested and in our site works:
https://d.pr/v/q34vAf
bootstrap.js includes support for tooltips, you may change the order of bootstrap.js file, because I have tested to re-include it and the tooltips should work fine:
https://d.pr/v/LVwUUl
I've added the following. But it shows an error.
Hi Yasin,
If you cannot access "$('.datepicker').datepicker();" then you can try this way:
Also make sure the date picker library is included. If its included load it in the end (before neon-custom.js)