PHP Matrimonial Script

Latest script
If U want Ur Matrimonial website please visit these link
Complete matrimonial script
See the demo at: - matrimonialtalk.com
Admin Panel: - matrimonialtalk.com/admin/login.php
Admin Details
User Name: -admin
Password: - admin
See the demo 2 at: - matchmatri.com
Admin Panel: - matchmatri.com/admin/login.php
Admin Details
User Name: -admin
Password: - admin
o     features
o     Guest Module:-
•     Member registration (paid or free)
•     Browse categories that are sorted by region, community,
•     religion Basic search on homepage
•     Advanced search with additional parameters
•     Non-members can see results of listings but with limited info
•     Members have unrestricted access to the complete profile
•     Featured profile listings on homepage along with thumbnail images
•     Static information pages Members Module :-
•     Membership Info
•     Manage membership account info
•     Order details
•     Email Alert Configuration
•     Change partner profile
•     Edit own profile
•     Upgrade Profiule
•     Upload Photos (multiple)
•     Protect Photo
•     Upload Horoscope
•     Family Info - Father, Mother name, status, etc.
•     Partner Preference
•     Contact Profiles
•     Hobbies
•     View Details of Members Search Module :-
•     Quick or Smart Search
•     Advanced Search
•     Search by Profile ID
•     Search by City/ State
•     Contact Members Module:-
•     Show or Express Interest
•     List of members whom I have accepted
•     List of members who have accepted me
•     List of members who have contacted me
•     List of members whom I have contacted
•     Listing of all incoming messages
•     Listing of all sent messages
•     Forward the profile to a friend
•     Send Personalized Messages
•     Bookmark Profile
•     Print Profile
•     Admin Module
•     1.Site Configuration
•     set the url details of the website and tilt , description of the site
•     you can edit the admin password
o     2.Members Approval
•     approve new profiles as profile will not come in search results till they
•     approve by admin
•     upgrade membership of members from free to paid
o     3.Horoscope Approval
•     approve the horoscope uploaded by members
o     4.Renewal Membership
?     renew membership of expired members
?     report of members who are going to expire
o     5.Members Report
•     see the inacive members
•     see the acive members
•     see the paid members
o     6. Delete Members
•     delete the inacive members
•     delete the acive members
•     delete the paid members
o     7.Caste
•     manage the cast and religion
o     8.Edit Membership Plans
•     edit membership plan
o     9.Members Photo Approval
•     approve the photo of members as untill you approve members photo it will not see online
o     10.Successstory Approval
•     approve success story uploaded by members
•     you can unapprove or delete success stories
o     11.Assured Contact Allocation
•     you can set/reset the no. of contacts for paid and unpaid members
•     12.Members Report
•     you can download members in excel format
•     you can see the sales report of paid members , when they become paid members and how they pay
•     viea report of all members
o     13.News Letter
•     you can send the news letter to all members , single member or group of members
•     sms messaging - disable as it requite API integration
•     14. Database CheckUp
•     check up database connectivity and functionality
o     15 Payment Features Module
•     Payment Entry Form
•     Sales Invoices
•     Sales Receipts
•     Consolidated Accounts Summary
•     Renewal for Paid Members
•     Payment Gateway Integration
•     Paypal, 2CO, CCAvenue, etc.
•     Credit Card Support
o     Reporting Features Admin Module
•     Inactive Members Report
•     Free/Active Members Report
•     Paid Members Report
•     Members Report by Reference
•     Customised Export to Excel Format
•     View Reports of users by City / Gender / Country
•     View Profiles by Religion
•     Edit Member Details
•     ADMIN Quick Search profiles
•     Reports in Excel Format.
o     Mailing Features Admin Module
•     Newsletter
•     Membership Expiry Reminder Notices
•     Additional available features
•     banner management
•     classified management
•     RSS
•     audio/video chat module
•     toolbar
•     weeding shop(complete cms application integrated)
•     SMS API installation
•     hosting solution
o     New Features: -
•     My Matches
•     Favorites
•     Members I am Looking for
•     Members Looking for me
•     Who visited my profile
•     Profiles viewed by me
•     Search
•     Who is online
•     Special Cases
•     Prefrence based Search
•     Massaging for paid members
•     Inbox
•     Sent mail
•     Draft mail
•     Compose
•     Trash
•     Message from admin
•     SMS message
•     Profile Management
•     My Account
•     Alert Manager
•     Certified Profiles
•     Validations for Mobile
•     Validations for Email
•     Trusted/featured/latest profiles
•     Profiles with icons
•     Verification code/ mail
•     Admin have control on cast and sub cast
•     Admin can edit and add data in any profiles
•     Profile of the week
•     Success story
•     Country/city/state search
•     Manage partner profile
•     Manage my search in member panel
•     Massage compose/draft/sent/trash/inbox in member panel
•     Massage by admin in member panel
•     Database backup at a click (both in server/system)
•     Hindi language Converter
o     there is some additional features are
complete sms api support
video support
manage all profiles through the admin
classified with all the world city's
wedding shop
banner advertisement or complete ad management
support ticket management
chat/forum/massage board module
member's photo and video protected
all the profiles are shows as domain.com/member name (it is very beneficial to members)
toolbar is now under development it'll be ready in a week
SEO friendly coding and also you can manage your keyword through the admin
recent profiles and featured profiles are shown at home page
trusted mark on profile
all the marks on profile like featured,mobile,horescope,chat etc. manage by admin
4 type more searching of profiles now the total searching is 10 type.
members can save search
•     and also we are developing mobile applications for this matrimonial script. through this members can get the support of mobile to access the website.
Thank You
Pm Me or Contact Me at
[email protected]
Tech Biz Solution
+91-9251026226

Do you know any server-scripting? What server models does
your host
support?
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.dreamweavermx-templates.com
- Template Triage!
http://www.projectseven.com/go
- DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs,
Tutorials & Resources
http://www.macromedia.com/support/search/
- Macromedia (MM) Technotes
==================
"2start" <[email protected]> wrote in
message
news:erpkp4$2bk$[email protected]..
>I am trying to set up an interactive calendar on a
website. I want the
>public
> to be able to select a class listed on the calendar and
it be linked to
> the
> class info.
>
> I have been told, I need to have a php script to use on
our linux server.
>
> Can someone please help me.. if I find a script where do
I put it in the
> code?
> I have found several sites with the code but I don't
know what to do with
> it...
>
> This is the look I am trying to achieve...
>
>
http://www.nccommerce.com/wdi/WDICalendar/default.asp?calid=9
>

Similar Messages

  • Is there a php transfer script?

    Has anyone written or stumbled uppon a PHP transfer script they can share?
    Thanks

    Well, I have found this.  I am having trouble understanding how to impliment it.  Does anyone have any helpful suggestions?
    http://omega1.uww.edu/itunesu/

  • Need help with PHP mail script [was: Can someone please help me?]

    I'm trying to collect data from a form and email it.  I'm using form2mail.php and the problem is that the email is not collecting the form info and it has the same email address in the From: and To: lines. I'm really stuck and would appreciate any help.
    Here is the HTML code:
    <!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>Contact Us</title>
    <style type="text/css">
    <!--
    .style1 {font-family: Verdana, Arial, Helvetica, sans-serif}
    .style2 {
    font-size: 14px;
    color: #000000;
    body {
    background-color: #FFFFFF;
    body,td,th {
    color: #CC3300;
    .style3 {font-size: 14px; font-weight: bold; }
    .style6 {font-size: 18px}
    .style7 {font-size: 16px}
    .style8 {font-size: 16px; font-family: Verdana, Arial, Helvetica, sans-serif; }
    .style9 {font-size: 16px; font-weight: bold; font-family: Verdana, Arial, Helvetica, sans-serif; }
    .style10 {color: #000000}
    -->
    </style>
    </head>
    <body>
    <div align="center"><img src="nav2.jpg" alt="nav bar" width="698" height="91" border="0" usemap="#Map2" />
      <map name="Map2" id="Map2">
      <area shape="rect" coords="560,9,684,38" href="accessories.html" />
    <area shape="rect" coords="456,8,548,38" href="contact.html" />
    <area shape="rect" coords="305,8,435,40" href="photog.html" />
    <area shape="rect" coords="187,9,283,39" href="services.html" />
    <area shape="rect" coords="81,10,167,39" href="aboutus.html" />
    <area shape="rect" coords="5,10,68,39" href="index.html" />
    </map>
      <map name="Map" id="Map">
        <area shape="rect" coords="9,9,69,39" href="index.html" />
        <area shape="rect" coords="83,11,165,39" href="aboutus.html" />
        <area shape="rect" coords="182,9,285,38" href="services.html" />
        <area shape="rect" coords="436,14,560,37" href="contact.html" />
        <area shape="rect" coords="563,14,682,38" href="accessories.html" />
      </map>
    </div>
    <p> </p>
    <form id="TheForm" name="TheForm" action="form2mail.php" method="post">
      <p align="center" class="style2">P<span class="style1">lease fill out form below for a &quot;free no obligation quote&quot; then click submit.</span></p>
      <p align="center" class="style3">(*Required Information)</p>
      <div align="center">
        <pre><strong><span class="style8">*Contact Name</span> </strong><input name="name" type="text" id="name" />
    <span class="style8"><strong>
    Business Name </strong></span><input name="bn" type="text" id="bn" />
    <span class="style8"><strong>*Phone Number <input type="text" name="first" size="3" onFocus="this.value='';"
        onKeyup="checkNumber(this.value); autoTab(this, document.TheForm.second);" maxlength="3" value="###" /> - <input type="text" name="second" size="3" onFocus="this.value='';" onKeyup="checkNumber(this.value); autoTab(this, document.TheForm.third);" maxlength="3" value="###" /> - <input type="text" name="third" size="4" onFocus="this.value='';" onKeyup="checkNumber(this.value); autoTab(this, document.TheForm.fourth);" maxlength="4" value="####"/> </strong></span>
    <strong><span class="style1">*</span><span class="style8">Email Address</span> <input name="email" type="text" id="email" />     </strong> </pre>
        <label><span class="style9">*Re-enter to confirm</span>
        <input name="emx" type="text" id="emx" /></label><br /><br /><span class="style9">
    <label></label>
        </span>
        <p><span class="style9">*Best time to call </span>
          <select name="name1[]" multiple size="1" >
            <option>8am-9am</option>
            <option>9am-10am</option>
            <option>10am-11am</option>
            <option>11am-12pm</option>
            <option>12pm-1pm</option>
            <option>1pm-2pm</option>
            <option>2pm-3pm</option>
            <option>3pm-4pm</option>
            <option>4pm-5pm</option>
            <option>5pm-6pm</option>
            <option>6pm-7pm</option>
            <option>7pm-8pm</option>
          </select>
          <br />
          <br />
          <span class="style9">Type of Location</span>
          <select name="name2[]" multiple size="1" >
            <option>Residential</option>
            <option>Commercial</option>
          </select>
          <br />
          <br />
            <span class="style1"><br />
            <strong><br />
              <span class="style6">*Type of Services Requested:</span></strong><br />
            </span><strong><span class="style10">(check all that apply)</span><br />
                </strong><br />
                <span class="style7"><span class="style1"><strong>Janitorial cleaning</strong></span>
                <input type="checkbox" name="checkbox[]" value="checkbox" multiple/>
                <br />
                </span><strong><br />
                  <span class="style8">Mobile Auto Detailing</span>
                <input type="checkbox" name="checkbox2[]" value="checkbox" multiple/>
                <br />
                <br />
                  </strong><span class="style9">Moving/Hauling</span>
          <input type="checkbox" name="checkbox3[]" value="checkbox" multiple/>
          <br />
          <br />
                  <span class="style9">Pressure washing</span>
          <input type="checkbox" name="checkbox4[]" value="checkbox" multiple/>
          <br />
          <br />
                  <span class="style9">Window washing</span>
          <input type="checkbox" name="checkbox5[]" value="checkbox" multiple/>
          <br />
          <br />
                  <span class="style9">Window Tinting</span>
          <input type="checkbox" name="checkbox6[]" value="checkbox" multiple/>
          <br />
          <br />
                  <span class="style9">Boat cleaning</span>
          <input type="checkbox" name="checkbox7[]" value="checkbox" multiple/>
          <br />
          <br />
                  <span class="style9">RV cleaning</span>
          <input type="checkbox" name="checkbox8[]" value="checkbox" multiple/>
          <br />
          <br />
                  <span class="style9">Motorcycle cleaning</span>
          <input type="checkbox" name="checkbox9[]" value="checkbox" multiple/>
          <br />
          <br />
          <br />
          <br />
          <input name="SB"  type="button" class="style9" value="Submit" onClick="sendOff();">
        </p>
      </div></label>
      <script language="JavaScript1.2">
    // (C) 2000 www.CodeLifter.com
    // http://www.codelifter.com
    // Free for all users, but leave in this  header
    var good;
    function checkEmailAddress(field) {
    // Note: The next expression must be all on one line...
    //       allow no spaces, linefeeds, or carriage returns!
    var goodEmail = field.value.match(/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.gov)|(\.org) |(\..{2,2}))$)\b/gi);
    if (goodEmail){
       good = true
    } else {
       alert('Please enter a valid e-mail address.')
       field.focus()
       field.select()
       good = false
    function autoTab(startPoint,endPoint){
    if (startPoint.getAttribute&&startPoint.value.length==startPoint.getAttribute("max length"))
    endPoint.focus();
    function checkNumber(phoneNumber){
    var x=phoneNumber;
    var phoneNumber=/(^\d+$)|(^\d+\.\d+$)/
    if (phoneNumber.test(x))
    testResult=true
    else{
    alert("Please enter a valid number.")
    phoneNumber.focus();
    phoneNumber.value="";
    testResult=false
    return (testResult)
    function sendOff(){
       namecheck = document.TheForm.name.value   
       if (namecheck.length <1) {
          alert('Please enter your name.')
          return
       good = false
       checkEmailAddress(document.TheForm.email)
       if ((document.TheForm.email.value ==
            document.TheForm.emx.value)&&(good)){
          // This is where you put your action
          // if name and email addresses are good.
          // We show an alert box, here; but you can
          // use a window.location= 'http://address'
          // to call a subsequent html page,
          // or a Perl script, etc.
          window.location= 'form2mail.php';
       if ((document.TheForm.email.value !=
              document.TheForm.emx.value)&&(good)){
              alert('Both e-mail address entries must match.')
    </script>
    </form>
    <p> </p>
    </body>
    </html>
    and here is the form2mail.php:
    <?php
    # You can use this script to submit your forms or to receive orders by email.
    $MailToAddress = "[email protected]"; // your email address
    $redirectURL = "http://www.chucksmobile.com/thankyou.html"; // the URL of the thank you page.
    $MailSubject = "[Customer Contact Info]"; // the subject of the email
    $sendHTML = FALSE; //set to "false" to receive Plain TEXT e-mail
    $serverCheck = FALSE; // if, for some reason you can't send e-mails, set this to "false"
    # copyright 2006 Web4Future.com =================== READ THIS ===================================================
    # If you are asking for a name and an email address in your form, you can name the input fields "name" and "email".
    # If you do this, the message will apear to come from that email address and you can simply click the reply button to answer it.
    # To block an IP, simply add it to the blockip.txt text file.
    # CHMOD 777 the blockip.txt file (run "CHMOD 777 blockip.txt", without the double quotes)
    # This is needed because the script tries to block the IP that tried to hack it
    # If you have a multiple selection box or multiple checkboxes, you MUST name the multiple list box or checkbox as "name[]" instead of just "name"
    # you must also add "multiple" at the end of the tag like this: <select name="myselectname[]" multiple>
    # you have to do the same with checkboxes
    Web4Future Easiest Form2Mail (GPL).
    Copyright (C) 1998-2006 Web4Future.com All Rights Reserved.
    http://www.Web4Future.com/
    This script was written by George L. & Calin S. from Web4Future.com
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 2 of the License, or
    (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.
    # DO NOT EDIT BELOW THIS LINE UNLESS YOU KNOW WHAT YOU ARE DOING ===================================================
    $w4fver =  "2.2";
    $ip = ($_SERVER['HTTP_X_FORWARDED_FOR'] == "" ? $_SERVER['REMOTE_ADDR'] : $_SERVER['HTTP_X_FORWARDED_FOR']);
    //function blockIP
    function blockip($ip) {
    $handle = @fopen("blockip.txt", 'a');
    @fwrite($handle, $ip."\n");
    @fclose($handle);
    $w4fx = stristr(file_get_contents('blockip.txt'),getenv('REMOTE_ADDR'));
    if ($serverCheck) {
    if (preg_match ("/".str_replace("www.", "", $_SERVER["SERVER_NAME"])."/i", $_SERVER["HTTP_REFERER"])) { $w4fy = TRUE; } else { $w4fy = FALSE; }
    } else { $w4fy = TRUE; }
    if (($w4fy === TRUE) && ($w4fx === FALSE)) {
    $w4fMessage = "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\"><html>\n<head><meta http-equiv=\"Content-Type\" content=\"text/html; charset=iso-8859-1\"></head><body><font face=3Dverdana size=3D2>";
    if (count($_GET) >0) {
    reset($_GET);
    while(list($key, $val) = each($_GET)) {
      $GLOBALS[$key] = $val;
      if (is_array($val)) {
       $w4fMessage .= "<b>$key:</b> ";
       foreach ($val as $vala) {
        $vala =stripslashes($vala);
        $vala = htmlspecialchars($vala);
        if (trim($vala)) { if (stristr($vala,"Content-Type:") || stristr($vala,"MIME-Version") || stristr($vala,"Content-Transfer-Encoding") || stristr($vala,"bcc:")) { blockip($ip); die("ILLEGAL EXECUTION DETECTED!"); } }
        $w4fMessage .= "$vala, ";
       $w4fMessage .= "<br>\n";
      else {
       $val = stripslashes($val);
       if (trim($val)) { if (stristr($val,"Content-Type:") || stristr($val,"MIME-Version") || stristr($val,"Content-Transfer-Encoding") || stristr($val,"bcc:")) { blockip($ip); die("ILLEGAL EXECUTION DETECTED!"); } }
       if (($key == "Submit") || ($key == "submit")) { } 
       else {  if ($val == "") { $w4fMessage .= "$key: - <br>\n"; }
         else { $w4fMessage .= "<b>$key:</b> $val<br>\n"; }
    } // end while
    }//end if
    else {
    reset($_POST);
    while(list($key, $val) = each($_POST)) {
      $GLOBALS[$key] = $val;
      if (is_array($val)) {
       $w4fMessage .= "<b>$key:</b> ";
       foreach ($val as $vala) {
        $vala =stripslashes($vala);
        $vala = htmlspecialchars($vala);
        if (trim($vala)) { if (stristr($vala,"Content-Type:") || stristr($vala,"MIME-Version") || stristr($vala,"Content-Transfer-Encoding") || stristr($vala,"bcc:")) {blockip($ip); die("ILLEGAL EXECUTION DETECTED!"); } }   
        $w4fMessage .= "$vala, ";
       $w4fMessage .= "<br>\n";
      else {
       $val = stripslashes($val);
       if (trim($val)) { if (stristr($val,"Content-Type:") || stristr($val,"MIME-Version") || stristr($val,"Content-Transfer-Encoding") || stristr($val,"bcc:")) {blockip($ip); die("ILLEGAL EXECUTION DETECTED!"); } }
       if (($key == "Submit") || ($key == "submit")) { } 
       else {  if ($val == "") { $w4fMessage .= "$key: - <br>\n"; }
         else { $w4fMessage .= "<b>$key:</b> $val<br>\n"; }
    } // end while
    }//end else
    $w4fMessage .= "<font size=3D1><br><br>\n Sender IP: ".$ip."</font></font></body></html>";
        $w4f_what = array("/To:/i", "/Cc:/i", "/Bcc:/i","/Content-Type:/i","/\n/");
    $name = preg_replace($w4f_what, "", $name);
    $email = preg_replace($w4f_what, "", $email);
    if (!$email) {$email = $MailToAddress;}
    $mailHeader = "From: $name <$email>\r\n";
    $mailHeader .= "Reply-To: $name <$email>\r\n";
    $mailHeader .= "Message-ID: <". md5(rand()."".time()) ."@". ereg_replace("www.","",$_SERVER["SERVER_NAME"]) .">\r\n";
    $mailHeader .= "MIME-Version: 1.0\r\n";
    if ($sendHTML) {
      $mailHeader .= "Content-Type: multipart/alternative;";  
      $mailHeader .= "  boundary=\"----=_NextPart_000_000E_01C5256B.0AEFE730\"\r\n";    
    $mailHeader .= "X-Priority: 3\r\n";
    $mailHeader .= "X-Mailer: PHP/" . phpversion()."\r\n";
    $mailHeader .= "X-MimeOLE: Produced By Web4Future Easiest Form2Mail $w4fver\r\n";
    if ($sendHTML) {
      $mailMessage = "This is a multi-part message in MIME format.\r\n\r\n";
      $mailMessage .= "------=_NextPart_000_000E_01C5256B.0AEFE730\r\n";
      $mailMessage .= "Content-Type: text/plain;   charset=\"ISO-8859-1\"\r\nContent-Transfer-Encoding: quoted-printable\r\n\r\n";  
      $mailMessage .= trim(strip_tags($w4fMessage))."\r\n\r\n";  
      $mailMessage .= "------=_NextPart_000_000E_01C5256B.0AEFE730\r\n";  
      $mailMessage .= "Content-Type: text/html;   charset=\"ISO-8859-1\"\r\nContent-Transfer-Encoding: quoted-printable\r\n\r\n";  
      $mailMessage .= "$w4fMessage\r\n\r\n";  
      $mailMessage .= "------=_NextPart_000_000E_01C5256B.0AEFE730--\r\n";  
    if ($sendHTML === FALSE) {
      $mailHeader .= "Content-Type: text/plain;   charset=\"ISO-8859-1\"\r\nContent-Transfer-Encoding: quoted-printable\r\n\r\n";  
      $mailMessage .= trim(strip_tags($w4fMessage))."\r\n\r\n";  
    if (!mail($MailToAddress, $MailSubject, $mailMessage,$mailHeader)) { echo "Error sending e-mail!";}
    else { header("Location: ".$redirectURL); }
    } else { echo "<center><font face=verdana size=3 color=red><b>ILLEGAL EXECUTION DETECTED!</b></font></center>";}
    ?>
    Thanks in advance,
    Glenn
    [Subject line edited by moderator to indicate nature of request]

    Using PHP to process an online form and send the input by email is very simple. The mail() function takes a minimum of three arguments, namely: the address the mail is being sent to, the subject line, and the body of the email as a single string. The reason some people use scripts like form2mail.php is because they don't have the knowledge or patience to validate the user input to make sure it's safe to send.
    Rather than attempt to trawl through your complex form looking for the problems, I would suggest starting with a couple of simple tests.
    First of all, create a PHP page called mailtest.php containing the following script:
    <?php
    $to = '[email protected]'; // use your own email address
    $subject = 'PHP mail test';
    $message = 'This is a test of the mail() function.';
    $sent = mail($to, $subject, $message);
    if ($sent) {
      echo 'Mail was sent';
    } else {
      echo 'Problem sending mail';
    ?>
    Save the script, upload it to your server, and load it into a browser. If you see "Mail is sent", you're in business. If not, it probably means that the hosting company insists on the fifth argument being supplied to mail(). This is your email address preceded by -f. Change the line of code that sends the mail to this:
    $sent = mail($to, $subject, $message, null, '[email protected]');
    Obviously, replace "[email protected]" with your own email address.
    If this results in the mail being sent successfully, you will need to adapt the code in form2mail.php to accept the fifth parameter. You need to change the following line, which is a few lines from the end of the script:
    if (!mail($MailToAddress, $MailSubject, $mailMessage,$mailHeader))
    Change it to this:
    if (!mail($MailToAddress, $MailSubject, $mailMessage,$mailHeader, '[email protected]'))
    Again, use your own email address instead of "[email protected]".
    Once you have determined whether you need the fifth argument, test form2mail.php with a very simple form like this:
    <form id="form1" name="form1" method="post" action="form2mail.php">
      <p>
        <label for="name">Name:</label>
        <input type="text" name="name" id="name" />
      </p>
      <p>
        <label for="email">Email:</label>
        <input type="text" name="email" id="email" />
      </p>
      <p>
        <label>
          <input type="checkbox" name="options[]" value="boat cleaning" id="options_0" />
          Boat cleaning</label>
        <br />
        <label>
          <input type="checkbox" name="options[]" value="RV cleaning" id="options_1" />
          RV cleaning</label>
        <br />
        <label>
          <input type="checkbox" name="options[]" value="motorcycle cleaning" id="options_2" />
          Motorcycle cleaning</label>
      </p>
      <p>
        <input type="submit" name="send" id="send" value="Submit" />
      </p>
    </form>
    If that works, you can start to make the form more complex and add back your JavaScript validation.

  • Need help with PHP mail script

    I  have created a  log in system  . In that when the  user completes the  registration process an auto reply(auto-reply@domain)  will generate and  sent this to users email id regarding about the user  name and password  (Lo gin Details). After formal approval from the admin  the user will  get a user activation mail with log in link.
    But , my problem is  these are work only for mail accounts from my  domain  only(test@domain). its not send any of above mentioned details  to other  mail services like gmail or yahoo etc.
    i discussed this   with some others, they said its the problem with your mail function   configuration. but i didn't get any needful information as am a  beginner  in PHP scripting.
    i have contacted this with my  hosting service they said its the  problem with  php mail () function  and use php mailer() instead mail().
    please give me a solution for the same..
    Here am ataching my code..
    <?php
    include 'dbc.php';
    $err = array();
    if($_POST['doRegister'] == 'Register')
    foreach($_POST as $key => $value) {
        $data[$key] = filter($value);
    if(empty($data['full_name']) || strlen($data['full_name']) < 4)
    $err[] = "ERROR - Invalid name. Please enter atleast 3 or more characters for your name";
    //header("Location: register.php?msg=$err");
    //exit();
    // Validate User Name
    if (!isUserID($data['user_name'])) {
    $err[] = "ERROR - Invalid user name. It can contain alphabet, number and underscore.";
    //header("Location: register.php?msg=$err");
    //exit();
    // Validate Email
    if(!isEmail($data['usr_email'])) {
    $err[] = "ERROR - Invalid email address.";
    //header("Location: register.php?msg=$err");
    //exit();
    // Check User Passwords
    if (!checkPwd($data['pwd'],$data['pwd2'])) {
    $err[] = "ERROR - Invalid Password or mismatch. Enter 5 chars or more";
    //header("Location: register.php?msg=$err");
    //exit();
    $user_ip = $_SERVER['REMOTE_ADDR'];
    // stores sha1 of password
    $sha1pass = PwdHash($data['pwd']);
    // Automatically collects the hostname or domain  like example.com)
    $host  = $_SERVER['HTTP_HOST'];
    $host_upper = strtoupper($host);
    $path   = rtrim(dirname($_SERVER['PHP_SELF']), '/\\');
    // Generates activation code simple 4 digit number
    $activ_code = rand(1000,9999);
    $usr_email = $data['usr_email'];
    $user_name = $data['user_name'];
    $rs_duplicate = mysql_query("select count(*) as total from users where user_email='$usr_email' OR user_name='$user_name'") or die(mysql_error());
    list($total) = mysql_fetch_row($rs_duplicate);
    if ($total > 0)
    $err[] = "ERROR - The username/email already exists. Please try again with different username and email.";
    if(empty($err)) {
    $sql_insert = "INSERT into `users`
                  (`full_name`,`user_email`,`pwd`,`address`,`tel`,`fax`,`website`,`date`,`users_ip`,`activa tion_code`,`country`,`user_name`
                VALUES
                ('$data[full_name]','$usr_email','$sha1pass','$data[address]','$data[tel]','$data[fax]',' $data[web]'
                ,now(),'$user_ip','$activ_code','$data[country]','$user_name'
    mysql_query($sql_insert,$link) or die("Insertion Failed:" . mysql_error());
    $user_id = mysql_insert_id($link); 
    $md5_id = md5($user_id);
    mysql_query("update users set md5_id='$md5_id' where id='$user_id'");
    //    echo "<h3>Thank You</h3> We received your submission.";
    if($user_registration)  {
    $a_link = "
    *****ACTIVATION LINK*****\n
    http://$host$path/activate.php?user=$md5_id&activ_code=$activ_code
    } else {
    $a_link =
    "Your account is *PENDING APPROVAL* and will be soon activated the administrator.
    $message =
    "Hello \n
    Thank you for registering with us. Here are your login details...\n
    User ID: $user_name
    Email: $usr_email \n
    Passwd: $data[pwd] \n
    $a_link
    Thank You
    Administrator
    $host_upper
    THIS IS AN AUTOMATED RESPONSE.
    ***DO NOT RESPOND TO THIS EMAIL****
        mail($usr_email, "Login Details", $message,
        "From: \"Member Registration\" <auto-reply@$host>\r\n" .
         "X-Mailer: PHP/" . phpversion());
      header("Location: thankyou.php"); 
      exit();
    ?>

    I  have created a  log in system  . In that when the  user completes the  registration process an auto reply(auto-reply@domain)  will generate and  sent this to users email id regarding about the user  name and password  (Lo gin Details). After formal approval from the admin  the user will  get a user activation mail with log in link.
    But , my problem is  these are work only for mail accounts from my  domain  only(test@domain). its not send any of above mentioned details  to other  mail services like gmail or yahoo etc.
    i discussed this   with some others, they said its the problem with your mail function   configuration. but i didn't get any needful information as am a  beginner  in PHP scripting.
    i have contacted this with my  hosting service they said its the  problem with  php mail () function  and use php mailer() instead mail().
    please give me a solution for the same..
    Here am ataching my code..
    <?php
    include 'dbc.php';
    $err = array();
    if($_POST['doRegister'] == 'Register')
    foreach($_POST as $key => $value) {
        $data[$key] = filter($value);
    if(empty($data['full_name']) || strlen($data['full_name']) < 4)
    $err[] = "ERROR - Invalid name. Please enter atleast 3 or more characters for your name";
    //header("Location: register.php?msg=$err");
    //exit();
    // Validate User Name
    if (!isUserID($data['user_name'])) {
    $err[] = "ERROR - Invalid user name. It can contain alphabet, number and underscore.";
    //header("Location: register.php?msg=$err");
    //exit();
    // Validate Email
    if(!isEmail($data['usr_email'])) {
    $err[] = "ERROR - Invalid email address.";
    //header("Location: register.php?msg=$err");
    //exit();
    // Check User Passwords
    if (!checkPwd($data['pwd'],$data['pwd2'])) {
    $err[] = "ERROR - Invalid Password or mismatch. Enter 5 chars or more";
    //header("Location: register.php?msg=$err");
    //exit();
    $user_ip = $_SERVER['REMOTE_ADDR'];
    // stores sha1 of password
    $sha1pass = PwdHash($data['pwd']);
    // Automatically collects the hostname or domain  like example.com)
    $host  = $_SERVER['HTTP_HOST'];
    $host_upper = strtoupper($host);
    $path   = rtrim(dirname($_SERVER['PHP_SELF']), '/\\');
    // Generates activation code simple 4 digit number
    $activ_code = rand(1000,9999);
    $usr_email = $data['usr_email'];
    $user_name = $data['user_name'];
    $rs_duplicate = mysql_query("select count(*) as total from users where user_email='$usr_email' OR user_name='$user_name'") or die(mysql_error());
    list($total) = mysql_fetch_row($rs_duplicate);
    if ($total > 0)
    $err[] = "ERROR - The username/email already exists. Please try again with different username and email.";
    if(empty($err)) {
    $sql_insert = "INSERT into `users`
                  (`full_name`,`user_email`,`pwd`,`address`,`tel`,`fax`,`website`,`date`,`users_ip`,`activa tion_code`,`country`,`user_name`
                VALUES
                ('$data[full_name]','$usr_email','$sha1pass','$data[address]','$data[tel]','$data[fax]',' $data[web]'
                ,now(),'$user_ip','$activ_code','$data[country]','$user_name'
    mysql_query($sql_insert,$link) or die("Insertion Failed:" . mysql_error());
    $user_id = mysql_insert_id($link); 
    $md5_id = md5($user_id);
    mysql_query("update users set md5_id='$md5_id' where id='$user_id'");
    //    echo "<h3>Thank You</h3> We received your submission.";
    if($user_registration)  {
    $a_link = "
    *****ACTIVATION LINK*****\n
    http://$host$path/activate.php?user=$md5_id&activ_code=$activ_code
    } else {
    $a_link =
    "Your account is *PENDING APPROVAL* and will be soon activated the administrator.
    $message =
    "Hello \n
    Thank you for registering with us. Here are your login details...\n
    User ID: $user_name
    Email: $usr_email \n
    Passwd: $data[pwd] \n
    $a_link
    Thank You
    Administrator
    $host_upper
    THIS IS AN AUTOMATED RESPONSE.
    ***DO NOT RESPOND TO THIS EMAIL****
        mail($usr_email, "Login Details", $message,
        "From: \"Member Registration\" <auto-reply@$host>\r\n" .
         "X-Mailer: PHP/" . phpversion());
      header("Location: thankyou.php"); 
      exit();
    ?>

  • Problem With Submitting Data to Php Mail Script.

    So i am working with this Flash template that my boss purchased. It has a contact form, you are supposed to be able to fill it out, and it sends an email to a specified email address.
    However, it does not work. At all!
    There are 4 Fields on the form
    name
    email
    phone
    message
    The Code for the Submit Button is
    -----Button Code-----
    onClipEvent(load){this.t.v =  _root.contacts_txt7;}
    on (rollOver) {this.gotoAndPlay("s1");}
    on (rollOut) {this.gotoAndPlay("s2");}
    on(release){
              _parent.loadVariables("inc/mail.php", "POST");
    ----Button Code-----
    The php script is
    ---------------Php Script------------------
    <?
    $name=$_POST['name'];
    $email=$_POST['email'];
    $phone=$_POST['phone'];
    $message=$_POST['message'];
    $ToEmail = "email@here";
    $ToSubject = "Message from your site";
    $EmailBody =   "Name: $name\n
                                            Email: $email\n
                                            Phone: $phone\n
                                            Message: $message\n";
    $Message = $EmailBody;
    $headers .= "Content-type: text; charset=iso-8859-1\r\n";
    $headers .= "From:".$name." / ".$email."\r\n";
    mail($ToEmail,$ToSubject,$Message, $headers);
    ?>
    ------------Php Script------------
    It seems like it should work. The mail function on the server works, as I am able to setup a basic php contact page, and it works, however, he wants this flash contact form. It's as if the flash is not sending anything to the php script. Is there something missing? I have stared at it for hours, and have resorted to banging my head on the wall in an effort to jar loose ideas, thus far, nothing. 

    that should be:
    $headers = "Content-type: text; charset=iso-8859-1\r\n";
    $headers .= "From:".$name." / ".$email."\r\n";
    and:
    on(release){
    trace(_parent.email+" "+_parent.name+" "+_parent.phone+" "+_parent.message);
              _parent.loadVariables("inc/mail.php", "POST");

  • PHP CGI scripts problem

    I am using iPlanet webserver on a Win 2000 machine. Amongst the other things
    I am doing with it, I have some PHP scripts which I want to run on it.
    I have followed the manual on CGI, but I cannot get it to work.
    After using the Admin setup, the 'obj.conf' file contains:
    NameTrans fn="pfx2dir" from="/abc" dir="c:/Netscape/Server4/xyz" name="cgi"
    Service fn="send-cgi" type="magnus-internal/cgi"
    <Object name="cgi">
    ObjectType fn="force-type" type="magnus-internal/cgi"
    Service fn="send-cgi"
    </Object>
    The 'mime.types' file contains:
    type=magnus-internal/cgi exts=cgi,exe,bat,php
    type=application/x-php exts=php
    Windows is set up to recognise '.php' extensions and run the PHP
    interpreter.
    The error message which I get is:
    [03/Oct/2001:16:38:51] failure ( 900): for host 132.132.132.132 trying to
    GET /zyz/test.php, send-cgi reports: could not send new process (The
    operation completed successfully.
    [03/Oct/2001:16:38:51] failure ( 900): cgi_send:cgi_start_exec
    c:\Netscape\Server4\abc\test.php failed
    Any ideas why this does not work?
    Steven

    Hi Steven ,
    Follow exactly
    http://benoit.noss.free.fr/php/install-php4.html
    to install and configure PHP in IWS under WIndowsNT.
    If it still does'nt works notify me.
    Regards
    T.Raghulan
    [email protected]

  • PHP Upload script for ZIP/SIT files

    Hi,
    I'm trying to locate a decent script that would allow clients
    to upload files to a Web site that I am working on. I found a basic
    one that works at www.w3schools.com/PHP/php_file_upload.asp.
    However, it lack the capabilities to upload zip and sit files.
    Could I modify the existing script that I just mentioned?
    Unfortunately, I am not very PHP saavy. I have been Googling for
    such a script but have not found one yet. I hope some one could
    recommend a decent script. Thanks.

    .oO(Mark A. Boyd)
    >Carlton Chin posted in macromedia.dreamweaver.appdev:
    >
    >> I'm trying to locate a decent script that would
    allow clients to
    >> upload files to a Web site that I am working on. I
    found a basic
    >> one that works at
    www.w3schools.com/PHP/php_file_upload.asp.
    >> However, it lack the capabilities to upload zip and
    sit files.
    >> Could I modify the existing script that I just
    mentioned?
    >
    >The ticket is where the script is checking
    $_FILES["file"]["type"].
    >See
    http://www.w3schools.com/media/media_mimeref.asp
    >
    >If you only want to allow zip/sit, try changing this:
    >
    ><?php
    >if ((($_FILES["file"]["type"] == "image/gif")
    >|| ($_FILES["file"]["type"] == "image/jpeg")
    >|| ($_FILES["file"]["type"] == "image/pjpeg"))
    >&& ($_FILES["file"]["size"] < 20000))
    Be careful. These informations can be faked or might not be
    available at
    all. I can easily upload a PHP script as "image/jpeg". If the
    file ends
    up in a public directory within the document root, I can
    execute it and
    then have a look at the entire server ...
    Relying on the content type or file extension is a huge
    security hole!
    I'm quite surprised that W3Schools publishes such an insecure
    script.
    To make sure that an uploaded file is really of the type you
    expect, you
    must look at its content! For images you can use
    getimagesize(), which
    will also return the type if it's a valid image. For other
    types you
    have to use other libs or external tools. On a *nix machine
    you could
    execute the shell command 'file' for example, which
    recognizes quite a
    lot of different file types.
    Micha

  • PHP Jabbers scripts

    Hi there,
    I'm using iWeb to create small business site. I was just wondering if any of you know if any of their scripts work for us iWeb site builders. Their web site is www.phpjabbers.com
    According to them it's easy, just copy and paste HTML code but I have red on forum that iWeb does not support PHP and MySQL. I was planing to buy their availability calendar script.
    Thanks a lot,
    Goran

    It's MobileMe that does not support php and mysql. If you are using a different server, I would imagine you can modify an iWeb site to do these things, though iWeb itself doesn't provide any tools for that.

  • Php form script assistance

    Hello please forgive me as I am new to this but really need assistance. I have a form created in html on a site and have tried numerous tutorials on creating a php script which would be linked to this html form, but each one I try either doesn't work or it seems as if it goes through but then I never recieve the mail in my mailbox. I used my yahoo account as well as another account and didn't get anything , can anyone please assist as to what I should do here is what I have so far.
    Thank you in advance for any assistance provided.
    HTML:
    <form name="contactform" method="post" action="mailer.php">
             Name          <input type="text" name="name"/><br/><br/>
             Email          <input type="text" name="email"/><br/><br/>
             Address      <input type="text" name="address"/><br/><br/>
             City            <input type="text" name="city"/><br/><br/>
             When to Contact <select name="dropdown">
                               <option value="Morning">Morning</option>
                               <option value="Afternoon">Afternooon</option>
                               <option value="Evening">Evening</option>
                               </select><br/><br/>
             Purpose of Contact <br/><textarea name="commment" rows="6" cols="40">
            </textarea><br/> <br/><input type="submit" value="Submit Form Now" name="submit"/>
            </form>
    Here is the script that I am using :
    <?php
    if(isset($_POST['submit'])) {
    $to = "[email protected]";
    $subject = "Inquiry Form";
    $name_field = $_POST['name'];
    $email_field = $_POST['email'];
    $address_field = $_POST['address'];
    $city_field = $_POST['city'];
    $comment= $_POST['comment'];
    $dropdown = $_POST['dropdown'];
    foreach($_POST['check'] as $value) {
    $check_msg .= "Checked: $value\n";
    $body = "From: $name_field\n E-Mail: $email_field\n $check_msg Option: $option\n Drop-Down: $dropdown\n Message:\n $message\n";
    echo "Data has been submitted to $to!";
    mail($to, $subject, $body);
    } else {
    echo "Form not Submitted!";
    ?>

    Hello thank you for responding... yes I believe it is , I have used a drag and drop flash component with a php script for another project I had worked on not too long ago and it worked fine. Im pretty sure it is running.
    Does the code and script that I provided look correct to you?

  • [PHP]simple script, works everywhere except Archlinux

    Here is my script. It works everywhere (Debian, Ubuntu, Gentoo, CentOS) except my new Arch distribution.
    <?php
    $domains_array = array();
    $tested_array = array();
    $id = "hgEqp";
    $queries = array('aaaa','bbbb','cccc');
    srand((float)microtime()*1000000);
    shuffle($queries);
    foreach ($queries as $query) {
    $url = 'http://some.url/&query='.$query;
    for($i=0;$i<10;$i++) {
    $array = unserialize(file_get_contents($url.(1+($i*100))));
    $array_result = $array['ResultSet']['Result'];
    foreach ($array_result as $a) {
    preg_match("[http://(www\..+?)\/(.+?)]", $a['Url'], $preg);
    if ($preg[1] != "" && !in_array($preg[1],$tested_array)) {
    array_push($tested_array, $preg[1]);
    $strona = @file_get_contents("http://".$preg[1]);
    if ((strpos($strona, "test string") != FALSE) || (strpos($strona, "test string 2") != FALSE) || (strpos($strona, "test string 3") != FALSE)) {
    if ((int)trim(exec('python ./test_page.py -s '.rawurlencode($preg[1]))) != 0) {
    array_push($domains_array, $preg[1]);
    echo "Domain ".$preg[1]." passed test and added to $domain_array...\n";
    sleep(10);
    echo "Finished page ".$i." of tested pages...\n";
    echo "Finished adding tested pages to array...\n";
    print_R($domains_array);
    ?>
    On Arch it isnt throwing any error, but it is doing nothing (and extremly fast, normally it works very long). Somebody knows why it isnt working on Arch?
    PS. I have Python installed and fopen allowed in php config
    Last edited by Dinth (2009-03-15 18:14:45)

    Well... putting your file in my Arch web server gives me a but of errors (as expected)  but the files is definitely read and processed.
    Warning: file_get_contents() [function.file-get-contents]: URL file-access is disabled in the server configuration in /home/ralvez/public_html/testing.php on line 18
    Warning: file_get_contents(http://humber.ca/&query=bbbb1) [function.file-get-contents]: failed to open stream: no suitable wrapper could be found in /home/ralvez/public_html/testing.php on line 18
    Warning: Invalid argument supplied for foreach() in /home/ralvez/public_html/testing.php on line 20
    Finished page 0 of tested pages...
    Warning: file_get_contents() [function.file-get-contents]: URL file-access is disabled in the server configuration in /home/ralvez/public_html/testing.php on line 18
    Try using /var/logs/httpd/error_log and /var/log/everything.log to find what's wrong with the file in your system.
    R.

  • PHP Form Scripting

    Please can someone help.
    I have created a form for a website that needs to do the following:
    1/ Be completed and submitted
    2/ On submission show a confirmation page to the customer.
    and 3/ Send an e-mail from the website and not from their own e-mail accout.
    We have designed the attached form and PHP script but it just does not seem to work, we can get parts other forms to work just not the whole thing.
    I am new to PHP and would be grateful if someone could have a look at it for me and change what they think is wrong.
    [Moderator Note:]   Moved to more appropriate forum:  You may also want to attach your page again - at the moment it's stuck in the queue.  Use the small camera icon to attach the file instead.

    From ur attached code, actually it was a HTML coding, not the PHP scripting..

  • What Internet Browser Settings Must Be Enable or Disabled for a PHP Form Script to Send a Form???

    Helo,
    I am running Windows XP Pro.
    What Are the Internet Browser Setting that can Stops my form''s data from being received as  emails.
    The Form Date is Received into Selected Email Boxes When the Form is Filled Out from Other PCs.
    http://www.collegestudentvoice.com/form.php
    1. All Emails boxes are set up.
    2. Have turned OFF NetworkSolution Firewall.
    3. Firefox  http referer is SET to  2.
    4. Form generated NO ERRORS  when I fill it out.
    cheers,
    Dreamweaver101.1

    Hello,
    The problem may be in a script but I also believe it has to do with my browser settings.
    How else to explain that the form's data is NOT  received  from my laptop but is received  from pc of my friend in LA and the form developer's pc.???
    There three files that deal with the form email script:
    1.   http://www.collegestudentvoice.com/form.php
    2.  http://www.collegestudentvoice.com/send-email-form.php
    3      FORM  ACTION.PHP File :
    <?php
      require_once('recaptchalib.php');
    $privatekey = "6LfwwsISAAAAAAPShkJ6nV3qkgLDHCe2uXj9RTWw";
      $resp = recaptcha_check_answer ($privatekey,
                                    $_SERVER["REMOTE_ADDR"],
                                    $_POST["recaptcha_challenge_field"],
                                    $_POST["recaptcha_response_field"]);
      if (!$resp->is_valid) {
        die ("The reCAPTCHA wasn't entered correctly. Go back and try it again." .
      else {
    include_once('Mail.php');
    include_once('Mail/mime.php');
    $errors ='';
    $max_allowed_file_size = 10000000; // size in KB
    $allowed_extensions = array("jpg", "jpeg", "gif", "bmp");
    $upload_folder = 'files/';
        $name_of_uploaded_file =  basename($_FILES['uploaded_file']['name']);
        $type_of_uploaded_file = substr($name_of_uploaded_file,
                                strrpos($name_of_uploaded_file, '.') + 1);
        $size_of_uploaded_file = $_FILES["uploaded_file"]["size"]/1024;
        if($size_of_uploaded_file > $max_allowed_file_size )
            $errors .= "\n Size of file should be less than $max_allowed_file_size";
        $allowed_ext = false;
        for($i=0; $i<sizeof($allowed_extensions); $i++)
            if(strcasecmp($allowed_extensions[$i],$type_of_uploaded_file) == 0)
                $allowed_ext = true;       
        if(!$allowed_ext)
            $errors .= "\n The uploaded file is not supported file type. ".
            " Only the following file types are supported: ".implode(',',$allowed_extensions);
        if(empty($errors))
            $path_of_uploaded_file = $upload_folder . $name_of_uploaded_file;
            $tmp_path = $_FILES["uploaded_file"]["tmp_name"];
            if(is_uploaded_file($tmp_path))
                if(!copy($tmp_path,$path_of_uploaded_file))
                    $errors .= '\n error while copying the uploaded file';
            $Business = Trim(stripslashes($_POST['Business']));
            $ProfessionalSports = Trim(stripslashes($_POST['ProfessionalSports']));
            $Humor101 = Trim(stripslashes($_POST['Humor101']));
            $CollegeSports = Trim(stripslashes($_POST['CollegeSports']));
            $Politics = Trim(stripslashes($_POST['Politics']));
            $EmailToBusiness = $Business . "@collegestudentvoice.net";
            $EmailToProfessionalSports = $ProfessionalSports . "@collegestudentvoice.net";
            $EmailToHumor101 =  $Humor101 ."@collegestudentvoice.net";
            $EmailToCollegeSports = $CollegeSports . "@collegestudentvoice.net";
            $EmailToPolitics = $Politics . "@collegestudentvoice.net";
            $EmailTo = "[email protected]";
            $EMailSubject = Trim(stripslashes($_POST['Subject']));
            $First = Trim(stripslashes($_POST['First']));
            $Last = Trim(stripslashes($_POST['Last']));
            $Email = Trim(stripslashes($_POST['Email']));
            $Suggestions = Trim(stripslashes($_POST['Suggestions']));
            $Body = "The following form has been filled";
            $Body .= "\n";
            $Body .= "---------------------------------------------------------------------------------";
            $Body .= "\n";
            $Body .= "\n";
            $Body .= "First Name: ";
            $Body .= $First;
            $Body .= "\n";
            $Body .= "Last Name: ";
            $Body .= $Last;
            $Body .= "\n";
            $Body .= "Email: ";
            $Body .= $Email;
            $Body .= "\n";
            $Body .= "Business: ";
            $Body .= $Business;
            $Body .= "\n";
            $Body .= "Professional Sports: ";
            $Body .= $ProfessionalSports;
            $Body .= "\n";
            $Body .= "Humor 101: ";
            $Body .= $Humor101;
            $Body .= "\n";
            $Body .= "College Sports: ";
            $Body .= $CollegeSports;
            $Body .= "\n";
            $Body .= "Politics: ";
            $Body .= $Politics;
            $Body .= "\n";
            $Body .= "Suggestions: ";
            $Body .= $Suggestions;
            $Body .= "\n";
            $Body .= "\n";
            $Body .= "---------------------------------------------------------------------------------\n";
            $Body .= "Emails sent to: " . strtolower($EmailToBusiness) . " / " .strtolower($EmailToProfessionalSports). " / " .strtolower($EmailToHumor101). " / " .strtolower($EmailToCollegeSports). " / ".strtolower($EmailToPolitics). "";
            $to = "[email protected]";
            $subject= $EMailSubject;
            $from = "[email protected]";
            $text = "\n $Body";
            $message = new Mail_mime();
            $message->setTXTBody($text);
            $message->addAttachment($path_of_uploaded_file);
            $body = $message->get();
            $extraheaders = array("From"=>$from, "Subject"=>$subject,"Reply-To"=>$Email);
            $headers = $message->headers($extraheaders);
            $mail = Mail::factory("mail");
            $mail->send($to, $headers, $body);
            if ($Business != "")
                        $mail->send(strtolower($EmailToBusiness), $headers, $body);
            if ($ProfessionalSports != "")
                        $mail->send(strtolower($EmailToProfessionalSports), $headers, $body);
            if ($Humor101 != "")
                        $mail->send(strtolower($EmailToHumor101), $headers, $body);
            if ($CollegeSports != "")
                        $mail->send(strtolower($EmailToCollegeSports), $headers, $body);
            if ($Politics != "")
                        $mail->send(strtolower($EmailToPolitics), $headers, $body);
            print "<meta http-equiv=\"refresh\" content=\"0;URL=form.php?suc=y\">";
    ?>

  • Php graphic script

    hi,
    i need a script to read from a file (query output) and draw a graph.
    query:
    select count(*),to_char(sysdate,'dd/mm/yyyy hh24:mi:ss') t from table where status=1;
    file:
    $vi file
    COUNT(*) T
    3080 24/06/2006 17:00:00
    COUNT(*) T
    3100 24/06/2006 17:30:00
    $
    thanks in advanced
    wisam

    Hi,
    I do not exactly understand, what you want to do.
    Do you want to run some queries and then write the output to a file?
    In PHP, $vi is a variable, and so you will get a WARNING from the parser, if you try to execute this snippet.
    1. You can do such things with a filehandle:
    Look at the filehandling functions at php.net
    http://de3.php.net/manual/en/function.fopen.php ,
    http://de3.php.net/manual/en/function.fwrite.php
    and
    http://de3.php.net/manual/en/function.fclose.php
    In this way you can open a file to append something, write the output of your query to the file, and close the file.
    2. In some cases, it may be easier, to get the queryresults to STDOUT, and redirect STDOUT to a file, using the ">>" operator.
    Greetings from Hamburg
    Thorsten

  • Help with newsletter PHP Mail script for mySQL / cron job

    I'm just trying to set up a PHP script to send emails as a cron job.
    It pretty much seems to work, but I can't get it to do two parts.
    The first part is to send the emails, and the second is to send a notification email to the site owner confirming that the emails have been sent.
    The script looks like:
    <?php
    include_once "connect_to_mysql.php";
    $sql = mysql_query("SELECT UserID, Firstname, Email, Newsletter_Received FROM Users WHERE Firstname='test' LIMIT 20");
    $numRows = mysql_num_rows($sql);
    $mail_body = '';
    while($row = mysql_fetch_array($sql)){
      $id = $row["UserID"];
      $email = $row["Email"];
      $name = $row["Firstname"];
      $mail_body = 'Test - please ignore';
        $subject = "Safari Awards Newsletter";
        $headers  = "From:[email protected]\r\n";
        $headers .= "Content-type: text/html\r\n";
        $to = "$email";
        $mail_result = mail($to, $subject, $mail_body, $headers);
      if ($mail_result) {
      mysql_query("UPDATE Users SET Newsletter_Received='1' WHERE Email='$email' LIMIT 20");
      } else {
    ?>
    <?php
    if ($numRows == 0) {
      $subj = "Newsletter Sent";
      $body = "The current newsletter has been sent to everyone.";
         $hdr  = "From:[email protected]\r\n";
         $hdr .= "Content-type: text/html\r\n";
         mail("[email protected]", $subj, $body, $hdr);
    ?>
    Basically with the line
    include_once "connect_to_mysql.php";
    included, it sends the emails as per the SELECT query, but does not send the 'Newsletter Sent' email.
    But if I take out that line, it obviously doesn't send the emails as per the SELECT query, but it does send the 'Newsletter Sent' email.
    Any suggestions on what might need changing in order for it to do both would be much appreciated!
    Thanks.

    Change this line -
    if ($numRows == 0) {
    to this -
    if ($mail_result) {

  • Php / html / script basics

    Hello all
    1) Please tell me how to redirect to a new window from php and html.
    There is php...
    header("location: next_page.php");'
    ... which which redirects in the SAME window and html...
    ...but how do open a NEW browsre window?
    2) My scripting sux!
    Actually it's non existant but I have to incorporate it :S
    Please tell me the simplest way to create 2 tables overlaying each other where each is activated by a mousover or mouse click on a tab?
    Thanks in advance
    Graeme

    My original reply was regarding question number 1.
    As for question 2, it sounds like you want to do something similar to a tab control in a real programming language. I hate to break it to you, but having the two tables loaded at the same time and swapping between them without making a request to the server isn't very easy, either.
    I'm sure there's a way to emulate what it sounds like you want to do, but it would be faster and easier to make two separate pages of content and have the user click a link to travel between them.

Maybe you are looking for

  • Officejet 7000 networking problems with usb printer

    connected up my new officejet 7000, replacing my deskjet 1280 on my pc, running xp sp3, networked on my work network. set up as shared printer. Showing on shared printer list on network, but when I try to install network printer on another machine on

  • Oracle workbench

    Does "Oracle Migration Workbench Release 10.1.0.4.0" support mysql ? if so where can i find the plugin for non oracle database it shows only "IBM and Informix" on plugin when i create Repository i get "No plugins are installed. please install the plu

  • How do I suppress scrolling of a ScrollPane via MouseWheel ?

    Hi all! I'm trying to suppress the scrolling via MouseWheel if the user has pressed the control key at time of scrolling, but I'm not able to do it. It doesn't matter at which node I add the ScrollEvent handler. The problem is, the ScrollEvent handle

  • Can't get lightroom to run after install

    I had the demo running on my mac for a while and last week time was up The start up screen would pop up and then it closed down. So I ordered the full package and installed from CD but its still closing the first window out so I can't register Any id

  • Interactive Report - CSV Enclosed By

    Hi All I notice that if you do not specifiy a value for CSV enclosed By then double quotes are use by default. Is there a way to set this to null i.e. not enclosed by anything. Cheers Shunt