none
created an ASPX pg for a form but will not work RRS feed

  • Question

  • Online I found a way to create a form, I followed all of the instructions and while I was working on the page and previewed it, it looked great. But when I went to publish, the page was all code when I checked it. I think there may be something going on when I attached it to my master dynamic web template. Can anyone help me figure out whats wrong here? Here is the code for the page.......

     

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <%@ Page Language="VB" %>
    <html dir="ltr" xmlns="http://www.w3.org/1999/xhtml">

    <!-- #BeginTemplate "master.dwt" -->

    <head>
    <!-- #BeginEditable "head" -->
    <title>Amazing Stoneoworks</title>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
    <link href="style%20sheets/contact.css" rel="stylesheet" type="text/css" />
    <!-- #EndEditable -->
    <link href="style%20sheets/style%20sheet.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript">
    <!--
    function FP_preloadImgs() {//v1.0
     var d=document,a=arguments; if(!d.FP_imgs) d.FP_imgs=new Array();
     for(var i=0; i<a.length; i++) { d.FP_imgs[i]=new Image; d.FP_imgs[i].src=a[i]; }
    }
    // -->
    </script>
    <style type="text/css">
    </style>
    <base target="shop.amazingstoneworks.com" />
    <script type="text/javascript">

      var _gaq = _gaq || [];
      _gaq.push(['_setAccount', 'UA-27984173-1']);
      _gaq.push(['_trackPageview']);

      (function() {
        var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
        ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
        var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
      })();

    </script>

     onload="FP_preloadImgs(/*url*/'button3D.gif',/*url*/'button3E.gif')">

    <div>
        <div id="header" style="height: 300px">
            <h1>Amazing Stoneoworks</h1>
            <div class="Tel_Fax">
                Tel. 1.800.998.6691<br />
                Fax.1.800.998.6572</div>
        </div>
        <div id="masthead" style="height: 30px">
            <h2>Our Only Limitation is Your Imagination</h2>
                </div>
        <div id="top_nav">
            <span class="auto-style1"><strong><a href="default.html" target="_self">Home</a><a href="Light-weight_Roof_Pavers.html" target="_self">Light-weight
            Roof Pavers</a><a href="About%20Us.html" target="_self">About Us</a><a href="Gallery.html" target="_self">Gallery</a></strong></span><a href="store.php" target="_self">Our Store</a><a href="Current_Projects.html" target="_self">Projects</a><a href="Contact%20Us.html" target="_self">Contact Us</a><br />
        </div>
        </div>
    </head>
        <!-- #BeginEditable "main_page_content" -->
    <html dir="ltr" xmlns="http://www.w3.org/1999/xhtml">
        <div>    <div class="location_content" style="width: 1000px; height: 286px; right: auto; left: auto;">
            <img alt="" class="castle" height="262" src="images/ginger-01.JPG" style="float: left" width="350" /><div class="address" style="width: 230px">
                <h3>We Are Located At:<table cellpadding="2" cellspacing="1" class="table" style="width: 230px; float: right; height: 251px;">
                    <tr>
                        <td class="table" colspan="2" valign="top">Bussiness
                        Hours </td>
                    </tr>
                    <tr>
                        <td class="table" style="height: 25px">Sunday </td>
                        <td class="table" style="height: 25px">Closed</td>
                    </tr>
                    <tr>
                        <td class="table">Monday</td>
                        <td class="table">8-5</td>
                    </tr>
                    <tr>
                        <td class="table">Tuesday</td>
                        <td class="table">8-5</td>
                    </tr>
                    <tr>
                        <td class="table">Wednesday</td>
                        <td class="table">8-5</td>
                    </tr>
                    <tr>
                        <td class="table">Thursday</td>
                        <td class="table">8-5</td>
                    </tr>
                    <tr>
                        <td class="table">Friday</td>
                        <td class="table">8-5</td>
                    </tr>
                    <tr>
                        <td class="table">Saturday</td>
                        <td class="table">9-3</td>
                    </tr>
                </table>
                <br />
                30 Gingerbread Castle Rd<br />Hamburg, NJ, 07419</h3>
                <br />
                <br />*Across from the Hamburg<br />Gingerbread Castle*</div>
    </div>
        <div>
        <form id="form1" runat="server" style="width: 395px; height: 457px">
            <asp:MultiView ID="YourForm" runat="server" ActiveViewIndex="0">
                <asp:View ID="FormContent" runat="server">
                            <label for="Email">
                            <span class="contact_txt">Enter your Email Address:</span><br />
                        <asp:TextBox ID="Email" runat="server" Columns="35" Width="173px"></asp:TextBox>
                    </label>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="Email"
                        Display="Dynamic" ErrorMessage="Please enter your email address." SetFocusOnError="True"
                        CssClass="ValidateMessage" ForeColor="">* Required</asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="Email"
                        ErrorMessage="Please enter a valid email address." SetFocusOnError="True" ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
                        CssClass="ValidateMessage" ForeColor="">* Please enter a valid email address.</asp:RegularExpressionValidator>
                    <br />
                      <br />
                            <label for="First_Name">
                            <span class="contact_txt">Name:</span><br />
                        <asp:TextBox ID="First_Name" runat="server" Columns="35" Width="173px"></asp:TextBox>
                    </label>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="First_Name"
                        ErrorMessage="Please enter your first name." SetFocusOnError="True" CssClass="ValidateMessage"
                        ForeColor="">* Required</asp:RequiredFieldValidator>
                    <br />
                    <br />
                            <label for="Message" class="contact_txt">
                        Please type your message below:
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="Message"
                            ErrorMessage="Please enter a message" SetFocusOnError="True" CssClass="ValidateMessage"
                            ForeColor="">* Required</asp:RequiredFieldValidator>
                        <br />
                        <asp:TextBox ID="Message" runat="server" TextMode="MultiLine" Columns="55" Rows="10" Width="293px"></asp:TextBox>
                    </label>
                    <br />
                    <br />
                            <label for="Category">
                            <span class="contact_txt">Category:</span><br />
                        <asp:DropDownList ID="Category" runat="server" Height="19px" Width="113px">
                            <asp:ListItem Value="none">select...</asp:ListItem>
                            <asp:ListItem>Sales Question</asp:ListItem>
                            <asp:ListItem>Customer Support</asp:ListItem>
                            <asp:ListItem>Information Request</asp:ListItem>
                            <asp:ListItem>Report a problem</asp:ListItem>
                            <asp:ListItem>Make a comment</asp:ListItem>
                            <asp:ListItem>Other</asp:ListItem>
                        </asp:DropDownList>
                    </label>
                    <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToValidate="Category"
                        ErrorMessage="Please select a category." Operator="NotEqual" ValueToCompare="none"
                        SetFocusOnError="True" CssClass="ValidateMessage" ForeColor="">    * Please select a category.</asp:CompareValidator>
                    <br />
                                   <br />
                    <asp:Button ID="SubmitForm" runat="server" OnClick="SubmitForm_Click" Text="Submit Form" />
                    <br />
                </asp:View>
                <asp:View ID="FormConfirmationMessage" runat="server">
                    Your message has been sent. Thank you for contacting us.<br />
                </asp:View>
                <asp:View ID="FormErrorMessage" runat="server">
                    Due to technical difficulty, your message may NOT have been sent.
                </asp:View>
                <asp:View ID="FormSpamMessage" runat="server">
                    You did not correctly answer the anti-spam question. Please go back and try again.</asp:View>
            </asp:MultiView>
           
        </form>

    </html>
    </div>
            </div>
            <div id="FormComfirmationMessage" style="height: 111px"></div>
        <!-- #EndEditable -->
        <div>
            <body>
        <div id="footer">
            <a href="default.html" style="color: #FF9900; font-family: Andalus; font-size: .9em; font-style: normal" target="_self">Home</a> |<a href="Light-weight_Roof_Pavers.html" style="font-family: Andalus; font-size: .9em; font-style: normal; color: #FF9900" target="_self">Light-weight
            Roof Pavers</a>|&nbsp;
            <a href="About%20Us.html" style="color: #FF9900; font-family: Andalus; font-size: .9em; font-style: normal" target="_self">About Us</a> |
            <a href="Gallery.html" style="color: #FF9900; font-family: Andalus; font-size: .9em; font-style: normal" target="_self">Gallery</a> |
            <a href="store.php" style="color: #FF9900; font-family: Andalus; font-size: .9em; font-style: normal" target="_self">Our Store</a>
            |<a href="Current_Projects.html" style="color: #FF9900; font: inherit; font-family: Andalus; font-size: .9em; font-style: normal" target="_self">Projects</a>|
            <a href="Contact%20Us.html" style="color: #FF9900; font-family: Andalus; font-size: .9em; font-style: normal" target="_self">Contact Us</a></div>

    </body>

    <html>
    <!-- #EndTemplate -->

    Thursday, January 5, 2012 12:41 PM

All replies

  • For questions, post a link to the published page, not the code.

    However, if your site is http://www.amazingstoneworks.com/, the answer is simple: you're trying to use an asp.net form on a hosting account that doesn't run asp.net.  You're on an Apache server.

    Thursday, January 5, 2012 2:01 PM
  • And as an aside, your specified font--Andalus--will not display on 99.9999% of computers because your visitors don't have it installed. And you haven't specified a font-family.
    Comic Sans walks into a bar. The bartender says, "Get out! We don't serve your type."
    Thursday, January 5, 2012 2:24 PM