Great question. I assume the modal only appears on a click or after the page has loaded? If this is the case, then you will need to use manual activation or conditional activation. This allows you to activate the experiment right when the modal appears.
We have a great support article on this. Check it out here:
Does this help clear things up for you? Let us know if you have additional questions!
The problem would actually more related to the results in your case (if the content is already loaded on the page). For example, someone may land on the page and get included in the experiment since your test is running on that page URL. However, they may never see the modal and the visitor count to the experiment would increase.
Using a form of activation (manual or conditional) will ensure that your visitor count only actually increases when the modal is shown.
The logic to manually activate should be pretty easy - you could even use a bootstrap experiment if you can't change your site's code. If you want to add the URL and instructions on how to get the modal to appear, then we can take a look at it for you!
Looking forward to hearing back.
I also have a problem using bootstrap modal in a variation.. the modal works fine it show when i click the link but the problem is afterwards that i click that link then the modal shows up it gets hang the whole page and it turns to blank page how will i fix that issue?
The best solution is the simplest.