Jump to content

code works in firefox but in ie


dennismonsewicz

Recommended Posts

in firefox my thank you for signing up shows up, in IE i get a blank black page and the form information is lost

 

here is my code:

 

<?php

$action = $_GET['action'];

	switch($action){
		case "signup":
			if(isset($_POST['submit'])) {
				$filename = "data.txt";
				$open = fopen($filename, "a+");

				$fname = stripslashes(ucwords($_POST['fm-firstname']));
				$lname = stripslashes(ucwords($_POST['fm-lastname']));
				$email = stripslashes($_POST['fm-email']);
				$address = stripslashes($_POST['fm-addr']);
				$city = stripslashes($_POST['fm-city']);
				$state = stripslashes($_POST['fm-state']);
				$zip = stripslashes($_POST['fm-zipcode']);
				$telephone = stripslashes($_POST['fm-telephone']);
				$fax = stripslashes($_POST['fm-fax']);
				$mobile = stripslashes($_POST['fm-mobile']);
				$comments = stripslashes($_POST['fm-comments']);

					if(stripslashes($_POST['newsopt']) == 'yes')
						{
							$opt = "yes";
						} else {
							$opt = "no";
							}

				fwrite($open, "First Name:\t$fname\n");
				fwrite($open, "Last Name:\t$lname\n");
				fwrite($open, "Email:\t$email\n");
				fwrite($open, "Address:\t$address\n");
				fwrite($open, "City:\t$city\n");
				fwrite($open, "State:\t$state\n");
				fwrite($open, "Zip Code:\t$zip\n");
				fwrite($open, "Telephone:\t$telephone\n");
				fwrite($open, "Fax:\t$fax\n");
				fwrite($open, "Mobile:\t$mobile\n");
				fwrite($open, "Comments:\t$comments\n");
				fwrite($open, "Future Updates?:\t$opt\n\n");
				fwrite($open, "------------------------------------\n\n");

				fclose($open);

				echo '<table align="center" id="Table_01" width="611" height="777" border="0" cellpadding="0" cellspacing="0">
					<tr>
						<td align="center" colspan="3" background="images/paperback2_01.jpg" width="611" height="100">
						</td>
					</tr>
					<tr>
						<td background="images/paperback2_02.jpg" width="35" height="578"></td>
						<td background="images/paperback2_03.jpg" width="538" height="578" valign="top"><div class="congrats">Thanks for signing up ' . $fname . '!<br /><br />
							<a href="index.html">Vist home page again?</a></div>
						</td>
						<td background="images/paperback2_04.jpg" width="38" height="578"></td>
					</tr>
					<tr>
						<td colspan="3" background="images/paperback2_05.jpg" width="611" height="99"></td>
					</tr>
				</table>';

			}

			break;
			exit;

		default: echo '
				<table align="center" id="Table_01" width="611" style="height: 777px" border="0" cellpadding="0" cellspacing="0">
					<tr>
						<td align="center" colspan="3" background="images/paperback2_01.jpg" width="611" height="100">
						  <p><b><font size="+2">Email  Request</font></b><br />
							<font size="-1">*Fields in <strong>bold</strong> are required. </font></p>
						</td>
					</tr>
					<tr>
						<td background="images/paperback2_02.jpg" width="35" height="578">			</td>
						<td align="center" background="images/paperback2_03.jpg" width="538" height="578">

						<!-- Form begins-->
						<div align="center" id="container">
				  <!-- p id="fm-intro" required for "hide optional fields" function -->

				  <form id="fm-form" method="post" action="signup.php?action=signup">
					 <fieldset style="margin-bottom:0px;">
					<span style="font-family:Arial, Helvetica, sans-serif; font-size:16px;"><b>Personal information</b></span>
					<div class="fm-req" style="margin-top:5px; margin-bottom:3px; font-size:12px">
					  <label for="fm-firstname">First name:</label>
					  <input name="fm-firstname" type="text" id="fm-firstname" class="required" size="25" />
					</div>
					<div class="fm-req" style="margin-bottom:3px;font-size:12px">
					  <label for="fm-lastname">Last name:</label>
					  <input name="fm-lastname" type="text" id="fm-lastname" class="required" size="25" />
					</div>
					<div class="fm-req" style="margin-bottom:8px; font-size:12px">
					  <label for="fm-email">Email:</label>
					  <input name="fm-email" type="text" id="fm-email" tabindex="" class="required" size="25" />
					</div>
					</fieldset>
					<fieldset style="margin-bottom:0px;">
					<span style="font-family:Arial, Helvetica, sans-serif; font-size:16px;"><b>Contact Information</b></span>
					<div class="fm-opt" style="margin-top:5px; font-size:12px">
					  <label for="fm-addr">Address:</label>
					  <input name="fm-addr" type="text" id="fm-addr" size="25" />
					</div>
					<div class="fm-opt" style="font-size:12px">
					  <label for="fm-city">City or Town:</label>
					  <input name="fm-city" type="text" id="fm-city" size="25" />
					</div>
					<div class="fm-opt" style="font-size:12px">
					  <label for="fm-state">State:</label>
					  <span class="fm-opt" style="font-size:12px">
					  <select id="fm-state" name="fm-state">
						<option value="" selected="selected">Choose a State</option>
						<option value="UNK">Outside US / Canada</option>
						<option value="AL">Alabama</option>
						<option value="AK">Alaska</option>
						<option value="AB">Alberta</option>
						<option value="AS">American Samoa</option>
						<option value="AZ">Arizona</option>
						<option value="AR">Arkansas</option>
						<option value="AA">Armed Forces Americas</option>
						<option value="AE">Armed Forces Europe</option>
						<option value="AP">Armed Forces Pacific</option>
						<option value="BC">British Columbia</option>
						<option value="CA">California</option>
						<option value="CO">Colorado</option>
						<option value="CT">Connecticut</option>
						<option value="DE">Delaware</option>
						<option value="DC">District Of Columbia</option>
						<option value="FL">Florida</option>
						<option value="GA">Georgia</option>
						<option value="GU">Guam</option>
						<option value="HI">Hawaii</option>
						<option value="ID">Idaho</option>
						<option value="IL">Illinois</option>
						<option value="IN">Indiana</option>
						<option value="IA">Iowa</option>
						<option value="KS">Kansas</option>
						<option value="KY">Kentucky</option>
						<option value="LA">Louisiana</option>
						<option value="ME">Maine</option>
						<option value="MB">Manitoba</option>
						<option value="MD">Maryland</option>
						<option value="MA">Massachusetts</option>
						<option value="MI">Michigan</option>
						<option value="MN">Minnesota</option>
						<option value="MS">Mississippi</option>
						<option value="MO">Missouri</option>
						<option value="MT">Montana</option>
						<option value="NE">Nebraska</option>
						<option value="NV">Nevada</option>
						<option value="NB">New Brunswick</option>
						<option value="NH">New Hampshire</option>
						<option value="NJ">New Jersey</option>
						<option value="NM">New Mexico</option>
						<option value="NY">New York</option>
						<option value="NF">Newfoundland</option>
						<option value="NC">North Carolina</option>
						<option value="ND">North Dakota</option>
						<option value="MP">Northern Mariana Is</option>
						<option value="NT">Northwest Territories</option>
						<option value="NS">Nova Scotia</option>
						<option value="OH">Ohio</option>
						<option value="OK">Oklahoma</option>
						<option value="ON">Ontario</option>
						<option value="OR">Oregon</option>
						<option value="PW">Palau</option>
						<option value="PA">Pennsylvania</option>
						<option value="PE">Prince Edward Island</option>
						<option value="PQ">Province du Quebec</option>
						<option value="PR">Puerto Rico</option>
						<option value="RI">Rhode Island</option>
						<option value="SK">Saskatchewan</option>
						<option value="SC">South Carolina</option>
						<option value="SD">South Dakota</option>
						<option value="TN">Tennessee</option>
						<option value="TX">Texas</option>
						<option value="UT">Utah</option>
						<option value="VT">Vermont</option>
						<option value="VI">Virgin Islands</option>
						<option value="VA">Virginia</option>
						<option value="WA">Washington</option>
						<option value="WV">West Virginia</option>
						<option value="WI">Wisconsin</option>
						<option value="WY">Wyoming</option>
						<option value="YT">Yukon Territory</option>
					  </select>
					  </span></div>
					<div style="margin:0px 0px 3px 0px; font-size:12px;">
					  <label for="fm-zipcode">Zip code:</label>
					  <input type="text" size="25" name="fm-zipcode" />
					</div>
					<div class="fm-opt" style="font-size:12px;">
					  <label for="fm-telephone">Telephone:</label>
					  <input name="fm-telephone" type="text" id="fm-telephone" title="Enter Phone Number in xxx-xxx-xxxx format" size="25" />
					 </div>
					  <div class="fm-opt" style="font-size:12px">
					  <label for="fm-fax">Fax:</label>
					  <input name="fm-fax" type="text" id="fm-fax" title="Enter Fax Number in xxx-xxx-xxxx format" size="25" />
					</div>
					<div class="fm-opt" style="font-size:12px">
					  <label for="fm-mobile">Mobile:</label>
					  <input name="fm-mobile" type="text" id="fm-mobile" size="25" />
					</div>
					<div class="fm-opt" style="margin-bottom:0px; font-size:12px">
					  <label for="fm-comments">Comments:</label>
					  <textarea name="fm-comments" cols="24" rows="3" id="fm-comments"></textarea>
					</div>
					<div align="center" class="fm-multi" style="margin-top:3px;">
					  <div align="center" class="fm-opt"> <p style="margin-bottom:3px;"><b>Would you like to be notified of future updates?</b></p>
					  <label for="fm-newsopt-yes" style="font-size:12px">
						<input name="newsopt" id="fm-newsopt-yes" value="yes" checked="checked" type="radio" />
						Yes</label>
						<label for="fm-newsopt-no" style="font-size:12px">
						<input id="fm-newsopt-no" name="newsopt" value="no" type="radio" />
						No</label>
					  </div>
					</div>
					</fieldset>

					<div id="fm-submit" class="fm-req">
					  <input name="submit" type="image" src="images/submit.png" value="submit" align="top" alt="send" />
					</div>
				  </form>
				</div>
							</td>
						<td background="images/paperback2_04.jpg" width="38" height="578">			</td>
					</tr>
					<tr>
						<td colspan="3" background="images/paperback2_05.jpg" width="611" height="99">			</td>
					</tr>
				</table>
				<!-- End ImageReady Slices -->';
				break;
				exit;
			}
	?>

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.