What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.

  • Profile Image

    I am using a form in a light box. I would like for someone to enter their email address before passing through to the page.

    Asked by chartcapture on March 28, 2014 at 04:11 PM

    Right now the user can either click behind the form to the page in the background and the form goes away to reveal the page, or they can click the "x" in the corner and access the page. Can I get rid of the "x" and prevent the user from accessing the page until the form is submitted? 

    Page URL:

  • Profile Image
    JotForm Support

    Answered by Mike_T on March 28, 2014 at 05:33 PM

    It should be possible to hide the X button and disable outside click by injecting the following CSS to your page:

    <style type="text/css">

    /* Disable clicks outside of lightbox */
    .jt-dimmer {
    pointer-events: none;
    /* Hide X close button */
    .jt-title div {
    display: none;


    However, the form will not close the lightbox upon receiving the entry. As a workaround, it is possible to set a Custom Thank You URL redirect on the form. It means that you will need two pages, one with Lighbox and second without one.

    Thank you.

  • Profile Image

    Answered by chartcapture on March 28, 2014 at 05:56 PM

    Thank you so much. Worked perfectly. 

  • Profile Image

    Answered by Cliff on June 20, 2016 at 06:49 PM


    The code is working as far as not letting the user click outside the light-box to close it but the "X" is still showing on the light-box.

    I injected the code exactly. What could be wrong? 

  • Profile Image
    JotForm Support

    Answered by jonathan on June 20, 2016 at 08:51 PM

    @ Cliff

    We will resolve your issue here https://www.jotform.com/answers/865179