<%
'****************************************************************************************
'**  Copyright Notice    
'**
'**  Web Wiz Guide - Web Wiz Email Form's 
'**                                                              
'**  Copyright 2001-2002 Bruce Corkhill All Rights Reserved.                                
'**
'**  This program is free software; you can modify (at your own risk) any part of it 
'**  under the terms of the License that accompanies this software and use it both 
'**  privately and commercially.
'**
'**  All copyright notices must remain in tacked in the scripts and the 
'**  outputted HTML.
'**
'**  You may use parts of this program in your own private work, but you may NOT
'**  redistribute, repackage, or sell the whole or any part of this program even 
'**  if it is modified or reverse engineered in whole or in part without express 
'**  permission from the author.
'**
'**  You may not pass the whole or any part of this application off as your own work.
'**   
'**  All links to Web Wiz Guide and powered by logo's must remain unchanged and in place
'**  and must remain visible when the pages are viewed unless permission is first granted
'**  by the copyright holder.
'**
'**  This program is distributed in the hope that it will be useful,
'**  but WITHOUT ANY WARRANTY; without even the implied warranty of
'**  MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR ANY OTHER 
'**  WARRANTIES WHETHER EXPRESSED OR IMPLIED.
'**
'**  You should have received a copy of the License along with this program; 
'**  if not, write to:- Web Wiz Guide, PO Box 4982, Bournemouth, BH8 8XP, United Kingdom.
'**    
'**
'**  No official support is available for this program but you may post support questions at: -
'**  http://www.webwizguide.info/forum
'**
'**  Support questions are NOT answered by e-mail ever!
'**
'**  For correspondence or non support questions contact: -
'**  info@webwizguide.com
'**
'**  or at: -
'**
'**  Web Wiz Guide, PO Box 4982, Bournemouth, BH8 8XP, United Kingdom
'**
'****************************************************************************************




'Set the response buffer to true so we execute all asp code before sending the HTML to the clients browser
Response.Buffer = True

'Dimension variables
Dim strBody 			'Holds the body of the e-mail
Dim objCDOMail 			'Holds the mail server object
Dim strMyEmailAddress 		'Holds your e-mail address
Dim strCCEmailAddress		'Holds any carbon copy e-mail addresses if you want to send carbon copies of the e-mail
Dim strBCCEmailAddress		'Holds any blind copy e-mail addresses if you wish to send blind copies of the e-mail
Dim strReturnEmailAddress	'Holds the return e-mail address of the user


'----------------- Place your e-mail address in the following sting ----------------------------------

strMyEmailAddress = "ahyat@perkasaforce.com"

'----------- Place Carbon Copy e-mail address's in the following sting, separated by ; --------------

strCCEmailAddress = "" 'Use this string only if you want to send the carbon copies of the e-mail

'----------- Place Blind Copy e-mail address's in the following sting, separated  by ; --------------

strBCCEmailAddress = "" 'Use this string only if you want to send the blind copies of the e-mail

'-----------------------------------------------------------------------------------------------------


'Read in the users e-mail address
strReturnEmailAddress = Request.Form("email")

'Initialse strBody string with the body of the e-mail
strBody = "<h2>E-mail enquiry sent from p website</h2>"
strBody = strBody &"<br>Name :" & Request.Form("visitor_name")
strBody = strBody &"<br>Tel:" & Request.Form("visitor_company")
strBody = strBody &"<br>Email:" & Request.Form("visitor_tel")
strBody = strBody &"<br>Subject :" & Request.Form("visitor_email")
strBody = strBody & "<br> Enquiry: - <br>" & Replace(Request.Form("visitor_enquiry"), vbCrLf, "<br>")

'Check to see if the user has entered an e-mail address and that it is a valid address otherwise set the e-mail address to your own otherwise the e-mail will be rejected
If Len(strReturnEmailAddress) < 5 OR NOT Instr(1, strReturnEmailAddress, " ") = 0 OR InStr(1, strReturnEmailAddress, "@", 1) < 2 OR InStrRev(strReturnEmailAddress, ".") < InStr(1, strReturnEmailAddress, "@", 1) Then
	
	'Set the return e-mail address to your own
	strReturnEmailAddress = strMyEmailAddress
End If	


'Send the e-mail

'Create the e-mail server object
Set objCDOMail = Server.CreateObject("CDONTS.NewMail")

'Who the e-mail is from (this needs to have an e-mail address in it for the e-mail to be sent)
objCDOMail.From = Request.Form("name") & " <" & strReturnEmailAddress & ">"

'Who the e-mail is sent to
objCDOMail.To = strMyEmailAddress

'Who the carbon copies are sent to
objCDOMail.Cc = strCCEmailAddress

'Who the blind copies are sent to
objCDOMail.Bcc = strBCCEmailAddress

'Set the subject of the e-mail
objCDOMail.Subject = "Website Enquiry from " & Request.Form("name")

'Set the e-mail body format (0=HTML 1=Text)
objCDOMail.BodyFormat = 0

'Set the mail format (0=MIME 1=Text)
objCDOMail.MailFormat = 0

'Set the main body of the e-mail
objCDOMail.Body = strBody

'Importance of the e-mail (0=Low, 1=Normal, 2=High)
objCDOMail.Importance = 1 

'Send the e-mail
objCDOMail.Send
	
'Close the server object
Set objCDOMail = Nothing
%>

<!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=utf-8" />
<title>PerkasaForce Sdn Bhd</title>
<link href="style.css" rel="stylesheet" type="text/css" />


<link rel="stylesheet" type="text/css" href="anylinkmenu.css" />
<script type="text/javascript" src="dropmenu.js"></script>


</head>

<body>

<div id="all">

<div id="header">

</div><!-- header -->

<div id="edit_contact">

<div id="left_column_in">

<div id="menu">


<div class= "mainlogo">
  <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="115" height="122">
    <param name="movie" value="media/logo.swf" />
    <param name="quality" value="high" />
    <param name="wmode" value="transparent" />
    <embed src="media/logo.swf" quality="high" wmode="transparent" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="115" height="122"></embed>
  </object>
</div>

  <div class="line">
    <!--#include file="imenus0.inc"-->
  </div>

</div><!-- menu -->

</div><!-- left column -->

<div id="right_column">
  <!-- hdr -->
  <div id="box_scroll">
    <div class="t"></div>
    <!-- t -->
    <div class="c">
      <div class="cnt">
        <h1><br />
          <br />
        </h1>
        <table width="350" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
            <td height="575" align="center" valign="top"><img src="images/tq.png" width="104" height="21" /><table width="100%" border="0" cellpadding="0" cellspacing="0">
              <tr>
                <td align="center"><p align="left"><font size="2" face="Verdana, Arial, Helvetica, sans-serif"><strong><font color="#0033FF" size="3">Thank-you
                  <% = Request.Form("name") %>
                  for completing the form. </font></strong><br />
                  <br />
                  We'll get  to  you shortly. <br />
                  <br />
                  <br />
                  </font><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Regards,<br />
                    Business Development<br />
                    <span class="BLUE1">PERKASAFORCE  SDN BHD </span></font></p></td>
              </tr>
              <tr>
                <td align="center"><p>&nbsp;</p>
                  <p><a href="http://www.perkasaforce.com"><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Visit 
                    Our Web Site </font></a></p></td>
              </tr>
            </table></td>
          </tr>
        </table>
        <h1>
</h1>
      </div>
      <!-- cnt -->
    </div>
    <!-- c -->
    <div class="b"></div>
    <!-- b -->
  </div>
  <!-- box 1 -->
<!-- box 2 -->
</div>
<!-- right column -->

<div class="clear"></div>

</div><!-- edit -->


<div id="footer">
  <div class="disclaimer"><div id="logo"></div>
  Copyright © 2009. All rights reserved.
  </div>
<div class="member">
  <img src="images/footer_logo.gif" alt=" " border="0" usemap="#Map" />
  <map name="Map" id="Map">
    <area shape="rect" coords="75,5,125,32" href="http://www.moha.gov.my" target="_blank" alt="Kementerian Dalam Negeri" />
    <area shape="rect" coords="132,5,164,32" href="http://www.kkppm.com" alt="Persatuan Perkhidmatan Kawalan Keselamatan Malaysia" />
    <area shape="rect" coords="82,16,90,19" href="#" />
    <area shape="rect" coords="93,22,95,23" href="#" />
  </map>
</div>
<div class="clear"></div>
</div>
<!-- footer -->

</div><!-- all -->

</body>


</html>
