<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Bum Records - Advertise</title>
<style type="text/css">
img{filter:none;}
a:hover img{-moz-opacity: 0.85;
filter:gray;}
</style>
<style type="text/css">
<!--
body,td,th {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
color: 000000;
}
body {
background-color: #333333;
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
a:link {
color: #CCCCCC;
text-decoration: underline;
}
a:visited {
text-decoration: underline;
color: #CCCCCC;
}
a:hover {
text-decoration: none;
color: 993300;
}
a:active {
text-decoration: underline;
color: #CCCCCC;
}
.style2 {font-size: 18px}
.style3 {font-size: 12px; }
.style5 {color: #FFFFFF}
.style6 {font-size: 12px; font-weight: bold; }
.style7 {color: #000000}
.style8 {font-size: 12px; font-weight: bold; color: #000000; }
-->
</style></head>
<body><center>
<table width="770" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><a href="index.html"><img src="images/newst_01.gif" width="250" height="121" border="0" /></a><img src="images/newst_02.gif" width="520" height="121" /></td>
</tr>
<tr>
<td bgcolor="#EEEEEE"><a href="index.html"><img src="images/newst_03.gif" width="63" height="33" border="0" /></a><a href="artists.html"><img src="images/newst_04.gif" width="82" height="33" border="0" /></a><a href="signup.html"><img src="images/newst_05.gif" width="96" height="33" border="0" /></a><a href="messageboard/"><img src="images/newst_06.gif" width="127" height="33" border="0" /></a><img src="images/newst_07.gif" width="402" height="33" /></td>
</tr>
</table>
<table bgcolor="#EEEEEE" width="770" border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="left" valign="top"><div class="style2" style="padding-left:5px;">
<p><u>Advertise </u></p>
<p class="style3">If you would like to advertise with us please fill out the form below.</p>
<div style="border-width:3px; border-style:solid; color:#666666; background-color:#999999; width:500px; padding-left:5px; padding-top:3px;"><form name="form1" id="form1" method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>">
<p class="style3 style7"><strong>What type of advertisement are you interested in?</strong></p>
<!-- Ad Types -->
<p class="style7">
<input type="checkbox" name="ad_type" value="Frontpage" />
<span class="style3">Frontpage</span></p>
<p class="style7">
<input name="ad_type" type="checkbox" class="style3" value="Banner" />
<span class="style3">Banner</span></p>
<p class="style7">
<input type="checkbox" name="ad_type" value="Custom" />
<span class="style3">Custom</span> </p>
<!-- / Ad Types -->
<!-- Company -->
<p class="style8">What type of company are you? </p>
<p class="style7">
<input name="company_type" type="radio" class="style3" value="Musician" />
<span class="style3">Musician</span> </p>
<p class="style7">
<input name="company_type" type="radio" class="style3" value="Label" />
<span class="style3">Label </span></p>
<p class="style7">
<input name="company_type" type="radio" value="Ad agency" />
<span class="style3">Advertising Agency </span></p>
<p class="style7">
<input name="company_type" type="radio" value="Not listed" />
<span class="style3">Company type not listed</span></p>
<!-- / Company -->
<!-- Online Advertising Before? -->
<p class="style8"> Have you ever advertised online before?</p>
<p class="style7">
<input name="advertised_before" type="radio" value="Yes" />
<span class="style3">Yes</span> <input name="advertised_before" type="radio" value="No" />
<span class="style3">No</span></p>
<!-- / Online Advertising Before? -->
<!-- Name, Email, Description -->
<p class="style8"> First Name</p>
<p class="style8">
<input name="first_name" type="text" value="" />
</p>
<p class="style8">Last Name</p>
<p class="style8">
<input type="text" name="last_name" />
</p>
<p class="style8">Email</p>
<p class="style8">
<input type="text" name="email" />
</p>
<p class="style8">Brief Company Description</p>
<p class="style6">
<textarea name="company_descr" cols="50"></textarea>
</p>
<!-- / Name, Email, Description -->
<p class="style6">
<input type="submit" name="Submit" value="Send" />
<input type="reset" name="Reset" value="Reset" />
</p>
</form>
<?php
if(isset($_POST['Submit']) && $_POST['Submit'] != '')
{
$ad_type = trim(strip_tags($_POST['ad_type']));
$company_type = trim(strip_tags($_POST['company_type']));
$advertised_before = trim(strip_tags($_POST['advertised_before']));
$first_name = trim(strip_tags($_POST['first_name']));
$last_name = trim(strip_tags($_POST['last_name']));
$email = trim(strip_tags($_POST['sender_email']));
$message = wordwrap(trim(strip_tags($_POST['company_descr'])), 70, "<br>\n");
$ip = (isset($_SERVER['HTTP_X_FORWARDED_FOR'])) ? $_SERVER['HTTP_X_FORWARDED_FOR'] : $_SERVER['REMOTE_ADDR'];
if(!preg_match("/^([a-zA-Z0-9])+([\.a-zA-Z0-9_-])*@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-]+)+/", $email))
{
echo '<br>E-mail is either invalid or left blank. Please check it and try again.';
}
else
{
$e = $email;
if(empty($ad_type) || empty($company_type) || empty($advertised_before) || empty($first_name) || empty($last_name) || empty($message))
{
echo '<br>One or more required fields left blank.';
}
else
{
$headers = 'MIME-Version: 1.0'."\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1'."\r\n";
$headers .= 'From: '.$first_name.' <'.$e.'>';
$send = mail("[email protected]", "Advertising on Bum Records", "
<html>
<head>
<title>Email from $first_name - About Advertising</title>
</head>
<body>
<table>
<tr>
<td colspan=\"2\">Someone is interested in advertising on Bum Records!</td>
</tr>
<tr>
<td><b>First Name:</b></td>
<td>$first_name</td>
</tr>
<tr>
<td><b>Last Name:</b></td>
<td>$last_name</td>
</tr>
<tr>
<td><b>Email:</b></td>
<td>$e</td>
</tr>
<tr>
<td><b>IP:</b></td>
<td>$ip</td>
</tr>
<tr>
<td><b>Ad Type:</b></td>
<td>$ad_type</td>
</tr>
<tr>
<td><b>Company Type:</b></td>
<td>$company_type</td>
</tr>
<tr>
<td><b>Advertised online before?</b></td>
<td>$advertised_before</td>
</tr>
<tr>
<td valign=\"top\"><b>Company Description:</b></td>
<td>$company_descr</td>
</tr>
</table>
</body>
</html>", $headers);
}
if($send)
{
echo '<br>Thank you, '.$name.', for enquiring about advertising on Bum Records.';
}
else
{
echo '<br>Seems to have been a problem sending the email. Please try again.';
}
}
}
?>
</div>
<p class="style3">ย </p>
<p class="style3"></p>
</div></td>
<td width="180px" align="left" valign="top"><p><script type="text/javascript"><!--
google_ad_client = "pub-2704045946477637";
google_alternate_color = "eeeeee";
google_ad_width = 180;
google_ad_height = 90;
google_ad_format = "180x90_0ads_al";
google_ad_channel ="";
google_color_border = "B4D0DC";
google_color_bg = "ECF8FF";
google_color_link = "0000CC";
google_color_url = "008000";
google_color_text = "6F6F6F";
//--></script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</td>
</tr>
</table>
<div class="style5" style="background-color:333333; text-align:left">Bum Records ยฉ 2005 -<span class="style5"> <a href="index.html">Home</a> - <a href="artists.html">Artists</a> - <a href="signup.html">Sign Up</a> - <a href="messageboard.html">Message Board</a> - <a href="advertise.html">Advertise</a> </span></div>
</center></body>
</html>