• 0
Sign in to follow this  
Followers 0

DMS 2 Modal is in front of page and blocks CTA


Question

Posted · Report post

Hi

You can see my problem here: https://www.dropbox.com/s/0t0fe6itgceorbx/Screenshot%202014-08-15%2012.07.57.png

So I have a modal. And even though it's invisible it's still there and blocks call to action buttons. 

 

I've inserted the modal in my functions.php useing pagelines_before_site -hook: 

add_action('pagelines_before_site', 'beforeSite');
    function beforeSite() { ?>


<!-- Modal -->
<div class="modal fade" id="modaali" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">


        <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><!--<span class="sr-only">Sulje</span>--></button>


        <h4 class="modal-title" id="myModalLabel">Ensimmäinen askel otettu!</h4>
      </div>
      <div class="modal-body">
<p class="leadi center">Jätä sähköpostisi tai puhelinnumerosi niin katsomme yhdessä kuinka Bitcoin voisi hyödyttää liiketoimintaasi.</p>
<?php echo do_shortcode( '[contact-form-7 id="44" title="Ei otsikkoa"]' ); ?>
      </div>
   <!--   <div class="modal-footer">
        <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
      </div>-->
    </div>
  </div>
</div>


    <?php
}

Is this how the modal should be working or is there a bug somewhere?

Could you give me a step-by-step instruction on how to use the modal so it's not there when it's hidden?

The site is not visible since I don't want to release a version where users cannot use the CTA, but I will if it's necessary for debuging.

Thank you!

 

Share this post


Link to post
Share on other sites

2 answers to this question

  • 0

Posted · Report post

Ok. I noticed that when I open it and close it, it then works. It was because it didin't have style="display:none" by default.

So I inserted style="display:none" to the modal and now it works. 

Is there a tutorial for the modals somewhere?

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi,

 

The issue is likely your code, as there is no issue when I use the modal shortcode, which is what we recommend you use. We do not provide support to user created code unfortunately.

 

If you want a tutorial on how to use modals, you will want to read the Bootstrap 2.x docs. which is what we use.

1 person likes this

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0