Form not working in reveal

  <!------CTA Form Section--------------------------------->
  <div id="transcroller-body" class="grid-x small-12 medium-12 large-12 cell aos-all" style="background-color:#4f7a23; padding:35px 35px 0px 35px;">
    <div class="large-12 medium-12 small-12 cell aos-item" data-aos="fade-up" style="padding-right:30px;">
      <h3 class="AvenirSub" style="text-align:center;color:#ffffff; font-size:35px !important; font-weight:normal;">We write <span style="color:#bad454; font-weight:bold; font-family:Tahoma, Geneva, sans-serif;">SUCCESS STORIES</span> and <span style="color:#bad454; font-weight:bold; font-family:Tahoma, Geneva, sans-serif;">DEFINE TOMORROWS</span>.</h3>
      <p class="insidePgHdr2 Quicksand" style="text-align:center; color:#ffffff !important;">Rewarding work is out there. We&rsquo;ll help you find it. Let's begin, together.</p>
     <br />
         
 <p align="center"><button type="button" class="conversationBtn" data-open="popmodal" href="#">START A CONVERSATION WITH US</button></p>
    </div>
  </div>
  <div class="grid-x fullWidth">
    <div class="large-12 medium-12 small-12 cell"> <img src="../New-AG-1019/img/bottom-CTA-section-box.jpg" alt="Start a conversation with Aureus Group" /></div>
    
    
    
  </div>
  <!------end CTA Form Section--------------------------------->
  
  <!---PopUp modal form------------------------------------------>
  <div class="reveal" id="popmodal" data-reveal data-close-on-click="true" data-animation-in="fade-in" data-animation-out="fade-out">
  <h1>Send Us a Message</h1>
  <!-- Start form -->
<a name="refresh"></a>
    <div class="error">
        <asp:Label ID="lblErrorMsg" runat="server" ForeColor="Red" ></asp:Label>
    </div>


<p class="ref-form">
<asp:TextBox Visible="false" ID="txtDate" runat="server"></asp:TextBox>

Name <span class="star">*</span> 
<br />
<asp:TextBox ID="txtName" runat="server"  CssClass="responsive-textbox"></asp:TextBox>
</p>

<br />

<p class="ref-form">
Email Address <span class="star">*</span> 
<br />
<asp:TextBox ID="txtEmail" runat="server"  CssClass="responsive-textbox"></asp:TextBox>
</p>

<br />

<p class="ref-form">
Phone <span class="star">*</span> 
<br />
<asp:TextBox ID="txtPhone" runat="server"   CssClass="responsive-textbox"></asp:TextBox>
</p>

<br />
	 
<p class="ref-form">
Message 
<br />
<asp:TextBox ID="txtComments" runat="server"  CssClass="responsive-textbox"  rows="3" textmode="MultiLine" ></asp:TextBox>
</p>

<p><div class="g-recaptcha" data-sitekey="6Lf5x8sUAAAAAN7ppeWjvFZEKBJLnEFLhqsrXd6Q"></div>
<asp:Label runat="server" ID="lblMessage"></asp:Label>
</p>	
    <p>
		
<asp:Button ID="btnSubmit" CssClass="button tiny2" Text="SUBMIT" OnClick="btnSubmit_Click" runat="server" /><br />
<span class="required">* Field is required</span></p>



		
 
 
    <asp:HiddenField ID="txtErrorMsg" Value="Check required fields." runat="server"/>
    <asp:HiddenField ID="txtSubmittedMsg"  Value="Your information has been submitted. Thank you!" runat="server"/>


 <!-- End form -->           
                    
<!-- This tag is required for the Search available Talent form to work -->                    
<p style="visibility:hidden">
    <Aureus:StaffingRequest Visible="false" runat="server" ID="staffRequest"  />
</p>
  <button class="close-button" data-close aria-label="Close reveal" type="button">
    <span aria-hidden="true">&times;</span>
  </button>
</div>
<!--------End PopUp Modal form------------------------------->

Hi,

please clarify what is not working.
Also please provide the version of Foundation Sites that you use.
Can you provide a working codepen so we can reproduce it there?

I’m using version 6.5.1
This is an asp.net form using a code file.

The form is placed in the modal and the pop up works but it is blocking the submit for the form. When you fill out the for and try to submit nothing happens. But when I pull the form outside of the modal I am able to submit.

Here is the code file:

using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Text;
using System.IO;
using Newtonsoft.Json;

public class ReCaptchaClass
{
    public static string Validate(string EncodedResponse)
    {
        var client = new System.Net.WebClient();

        string PrivateKey = "6Lf5x8sUAAAAAHDJHzPUhiygZ7F_wE-FEDmpYN9W";

        var GoogleReply = client.DownloadString(string.Format("https://www.google.com/recaptcha/api/siteverify?secret={0}&response={1}", PrivateKey, EncodedResponse));

        var captchaResponse = Newtonsoft.Json.JsonConvert.DeserializeObject<ReCaptchaClass>(GoogleReply);

        return captchaResponse.Success.ToLower();
    }

    [JsonProperty("success")]
    public string Success
    {
        get { return m_Success; }
        set { m_Success = value; }
    }

    private string m_Success;
    [JsonProperty("error-codes")]
    public List<string> ErrorCodes
    {
        get { return m_ErrorCodes; }
        set { m_ErrorCodes = value; }
    }


    private List<string> m_ErrorCodes;
}

public partial class staffing_Form : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
lblErrorMsg.Text = “”;

   // lblSubmittedMsg.Text = "";
    txtDate.Text = DateTime.Now.Date.ToString("MM-dd-yyyy"); 

}

protected void btnSubmit_Click(object sender, EventArgs e)
{
    if(!ValidateInputs())
    {
        lblErrorMsg.Text = txtErrorMsg.Value;

        return;
    }
    
   // string honey = txtHoney.Text;

   // if (honey != ""){

   // Response.Redirect("https://www.aureusgroup.com");
  //  }
//	string captcha = txtCaptcha.Text;

  //  if (captcha == Session["LoyatyMathCaptcha"].ToString())
  //  {

string EncodedResponse = Request.Form[“g-Recaptcha-Response”];
bool IsCaptchaValid = (ReCaptchaClass.Validate(EncodedResponse) == “true” ? true : false);

if (IsCaptchaValid) {

    StringBuilder sb = new StringBuilder();
    sb.AppendFormat("Submit Date: {0}\n", txtDate.Text);
    sb.AppendFormat("Name: {0}\n", txtName.Text);
    sb.AppendFormat("Email Address: {0}\n", txtEmail.Text);
    sb.AppendFormat("Phone: {0}\n", txtPhone.Text); 
    sb.AppendFormat("Additional Comments:\n{0}\n", txtComments.Text.Replace(Environment.NewLine, "; " ));

    string body = sb.ToString();
    string subject = "Contact for Aureus Group";
    string mailTo = txtMailTo.Value;
    string copyTo = txtCCTo.Value;
    
// string filename = Server.MapPath("\\") + "\\form\\contact.csv";
    
    // send the message
    AureusGroup.WebService.EmailInformation content = new AureusGroup.WebService.EmailInformation();
    content.ToEmails = mailTo;
    content.CCEmails = copyTo;
    content.Subject = subject;
    content.Body = body;
    content.FromEmail = "omaha@aureusgroup.com";
    content.TextType = AureusGroup.WebService.EmailBodyType.Text;
   // AureusGroup.WebService.EmailService email = new AureusGroup.WebService.EmailService();
    //email.SendEmail(content);

    // write the message
   // StreamWriter sw = new StreamWriter(filename, true);
   // sw.WriteLine(sb.ToString());


    //email the string
    AureusGroup.WebService.EmailService email = new AureusGroup.WebService.EmailService();
    email.SendEmail(content);

   // sw.Close();

    ResetInputFields();
  //  lblSubmittedMsg.Text = txtSubmittedMsg.Value;
    Response.Redirect("\\form\\contact-thank-you.aspx");
    }

// else
// {
// lblMessage.Text = “<span style=“color:red;”>Please complete the recaptcha.
”;
// }
// }

    else
    {
        lblMessage.Text = "<span style=\"color:red;\">Your answer is incorrect!</span><br />";
    }
}

private bool ValidateInputs()
{
    if (
          string.IsNullOrEmpty(txtName.Text.Trim()) 
        || string.IsNullOrEmpty(txtEmail.Text.Trim())
        || string.IsNullOrEmpty(txtPhone.Text.Trim()) 

// || string.IsNullOrEmpty(txtCaptcha.Text.Trim())
)
return false;
else
return true;
}

private void ResetInputFields()
{
    txtName.Text = "";
    txtPhone.Text = "";
    txtEmail.Text = "";
    txtComments.Text = "";	
	
}

}

We need a simple codepen to reproduce it. Just a bit static html with jQuery and Foundation Sites.

It appears that Elena Zhdanova had a solution to fix this but this link is rediredted to the forum front page. I’m not liking the new set up for the forum. It’s hard to navigate and the resources that I search for do not come up.
How do I access this article that was in the forum??
(http://foundation.zurb.com/forum/posts/1187-aspnetfoundation-reveal-modal)

The old forum was shut down. Unfortunately the content was not migrated. You could chrck if it is still in some Google cache or similar.

https://web.archive.org/web/2017*/http://foundation.zurb.com/forum/posts/1187-aspnetfoundation-reveal-modal

https://web.archive.org/web/20170719014019/http://foundation.zurb.com/forum/posts/1187-aspnetfoundation-reveal-modal

Not available. Is the an article for reveal and forms out there?

Did you check the last link in my reply? I saw the mentioned answer there.