Jump to content

Recommended Posts

Edit:

Ok I added a confirm.php file and now when clicking submit it goes straight to the confirm.php page and doesn't seem to be running the process.php page. Not sure what's going a little confused here.

 

Ok, I have a registration.php page on my site that's pretty basic, but when I click the submit button it gets stuck on the process.php page and doesn't complete, below is the coding to both pages any help would be greatly appreciated, also there's a link to the actual page

 

http://www.recoverytucson.org/registration.php

 

 

registration.php file

<!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>Untitled Document</title>
<link href="styles/main.css" type="text/css" rel="stylesheet"/>
<link href="index.html-files/styles_cnvu3.css" type="text/css" rel="stylesheet"/>


</head>

<body>
<table width="800" border="1" bordercolordark="#60A2B7" bordercolorlight="#60A2B7" align="center" cellpadding="1" cellspacing="0">
  <tr>
    <td align="center" valign="top">
    	<div id="topheader" style="width:800px; height:85px">
        	<h1 id="title">Recovery Tucson<br /></h1>
        </div>
        <div id="navbar" style="width:800px;" align="center">
          <!-- Begin Vista-Buttons.com -->
          <ul id="vbUL_7nvu3" class="vbULcnvu3" style="visibility:hidden;">
            <li><a href="2009.php" title="Recovery Walk 2009">Recovery Walk 2009</a></li>
            <li><a href="2008.php" title="Recovery Walk 2008">Recovery Walk 2008</a></li>
            <li><a href="2007.php" title="Recovery Walk 2007">Recovery Walk 2007</a></li>
            <li><a href="2006.php" title="Recovery Walk 2006">Recovery Walk 2006</a></li>
          </ul>
          <script type="text/javascript"> var vbImgPath="index.html-files/"</script>
          <script type="text/javascript" src="index.html-files/sccnvu3.js"></script>
          <table id="vista-buttons.com:idcnvu3" width="0" cellpadding="0" cellspacing="0" border="0">
            <tr>
              <td style="padding-right:0px" title ="Home"><a href="index.html" onmouseover='xpe("cnvu3o");' onmouseout='xpe("cnvu3n");' onmousedown='xpe("cnvu3c");'><img id="xpi_cnvu3" src="index.html-files/btcnvu3_0.png" name="vbcnvu3" width="108" height="30" border="0" alt="Home" /></a></td>
              <td style="padding-right:0px" title ="Events"><a href="events.php" onmouseover='xpe("dnvu3o");' onmouseout='xpe("dnvu3n");' onmousedown='xpe("dnvu3c");'><img id="xpi_dnvu3" src="index.html-files/btdnvu3_0.png" name="vbdnvu3" width="108" height="30" border="0" alt="Events" /></a></td>
              <td style="padding-right:0px" title ="Photo Gallery"><a onmouseover='xpe("7nvu3o");xpshow("7nvu3",0,this);xpsmover(this);' onmouseout='xpsmout(this);' onmousedown='xpe("7nvu3c");'><img id="xpi_7nvu3" src="index.html-files/bt7nvu3_0.png" name="vb7nvu3" width="108" height="30" border="0" alt="Photo Gallery" /></a></td>
              <td style="padding-right:0px" title ="Contact"><a href="contact.php" onmouseover='xpe("qnvu3o");' onmouseout='xpe("qnvu3n");' onmousedown='xpe("qnvu3c");'><img id="xpi_qnvu3" src="index.html-files/btqnvu3_0.png" name="vbqnvu3" width="108" height="30" border="0" alt="Contact" /></a></td>
              <td style="padding-right:0px" title ="Registration"><a href="registration.php" onmouseover='xpe("mnvu3o");' onmouseout='xpe("mnvu3n");' onmousedown='xpe("mnvu3c");'><img id="xpi_mnvu3" src="index.html-files/btmnvu3_0.png" name="vbmnvu3" width="108" height="30" border="0" alt="Registration" /></a></td>
            </tr>
          </table>
          <!-- End Vista-Buttons.com -->
	</div>
        	<div id="content" align="left">
			<center><font size="+1"><strong><u>Recovery Walk & Expo 2010 Pledge Form</u></strong></font></center>
                <br />
			<br />
			<table width="730" height="406" border="0">
  					<tr>
					 <td width="276" valign="top"><p align="center"><strong>Recovery Walk & Expo 2010</strong><br />
  						<img src="images/clip_image002.jpg" alt="" width="135" height="110" /></p>
  						<p align="center"><strong>Saturday, September 25 ~ 8am-1pm</strong><br />
  						<strong>Reid Park ~ Tucson, AZ</strong></p>
  						<p align="center"><strong>This Year at Recovery Walk & Expo:</strong><br />
   							Live Music<br />
    						Guest Speakers<br />
    						Recovery Activities/Service Providers<br />
    						Great Food<br />
    						Children Activities<br />
    						Spray  Can Art Competition
                        </p>
  						<p align="center"><strong>Registration for the walk requires a $20  Personal Pledge for Recovery* <br />
  							</strong>(Includes  T-Shirt)<br />
  							<br />
    						*The $20 is <strong>not</strong> mandatory to participate in the walk & expo. But you must register to  participate.
                        </p>
  						<p align="center">Please Bring Your Monies with You<br />
    						Make Checks Payable to:</p>
  						<p align="center"><strong>H.O.P.E. Recovery, Inc</strong>.<br />
    						(Donations are tax deductible to the extent allowable  by law)<br />
  							<strong>Tax ID # 16-1755583</strong></p>
  						<p align="center"><strong> </strong></p>
						<p align="center"> </p>
  						<img src="images/clip_image002_0000.jpg" alt="" width="276" height="138" />
                    </td>
  					<td width="444" valign="top">
  						<form action="process.php" method="POST" enctype="multipart/form-data" webbot-action="--WEBBOT-SELF--">
   							Name: <input type="text" name="FName" size="45"><br />
  							<br />
   							Address: <input type="text" name="FAddress" size="45"><br />
  							<br />
    						City: <input type="text" name="FCity" size="15" />
    						State: <input type="text" name="FState" size="2" />
    						Zip Code: <input type="text" name="FZip" size="5" /><br />
  							<br />
    						Phone: <input type="text" name="FPhone" size="15" /><br />
  							<br />
    						E-Mail: <input type="text" name="FEMail" size="45" /><br />
  							<br />
    						Please Check Level of Participation:<br />
    						(Get 5 Friends & Walk As A Team!)<br />
  							<br />
    						Total:Â <br />
  							<br />
  							<input type="submit" value="Submit" name="B1">
  							<input type="reset" value="Reset" name="B2">
  							<br />
  							<br />
  							</form>
  							<br />
                            <font size="1">
                            <strong>40% of the walk proceeds Will Go to  H.O.P.E. Recovery, Inc.</strong><br />
  							<strong>60% of the walk proceeds can go to your  favorite non-profit organization:</strong><br />
  							</font>
                            <br />
                            <font size="1"><strong>Waiver:</strong> I hereby release H.O.P.E. Recovery, Inc., Calvary Christian Fellowship  of Tucson, The City of 				Tucson, Pima County, Reid Park, all personnel, any  co-sponsoring organizations or agencies from responsibility for any injuries or  damages I may incur as a result of my participation in Recovery Walk & Expo  2010. I assume all risks associated with this walk including but not limited to  falls, traffic, and condition of sidewalks and weather conditions. I hereby  certify that I am in good physical condition an am able to walk in this event.  Additionally, I will permit the use of my picture in broadcast, print, etc.<br />
    						This  entry is invalid unless signed by entrant. If entrant is under 18, a parent or  guardian must sign entry. An adult must accompany children under 8.</font>
  							<br />
  							<br />
  							<p align="center"><strong>Name of non-profit organization</strong></p>
  							<p align="center">For More Information  Contact:<br />
  							<img src="images/clip_image002.gif" alt="" width="115" height="62" /><br />
    						1645 W. Valencia Rd. #109-404<br />
    						Tucson, AZ. 85746<br />
  							<strong>(520) 409-8869 or 292-9661 </strong><br />
  							<strong>Fax: 888-876-8710</strong><br />
    						info@recoverytucson.org<br />
    						www.recoverytucson.org</p>
  						</td>
  					</tr>
			</table>
		</div>
		<div id="footer">
        		<div id="footer_bg" align="left">
        			<div id="design">
					Design by Mark Jackson
				</div>
			Copyright © 2010 Recovery Tucson. | All Rights Reserved
       	  	</div>
        </div>
    </td>
  </tr>
</table>

</body>
</html>

 

 

process.php file

<?php
if ( ! $conf = formmail() )
{
        header('Location: http://www.recoverytucson.org/error.html');
}
else
{
        header('Location: http://www.recoverytucson.org/confirm.php');
}


function formmail()
{
    $form_elements= array(
                                                'FName' => 'Persons Name',
                                                'FAddress' => 'Address',
                                                'FCity' => 'City',
											'FState' => 'State',
											'FZip' => 'Zip Code',
											'FPhone' => 'Phone Number',
                                                'FEMail' => 'EMail Address',
                                                        );
                                                                
        $MailBody = '<html><body>';
                                                                
        while( list( $key, $value ) = each( $form_elements ) )
        {
                if ( empty( $_POST[$key] ) )
                                {
                                        return false;
                                }
                                $MailBody .= $value. '<p>'. strip_tags( $_POST[$key] ) . ' :</p>';
        }
        
        $MailTo = 'smeegols@gmail.com'; //email to send the results to
        $MailSubject = 'Registration'; //text in the Subject field of the mail
        $MailSent = 'Thank you for registering with us, We will reply within 24 hours.'; //confirm image
        $MailHeader = 'MIME-Version: 1.0' . "\r\n";
        $MailHeader .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
        $MailHeader .= 'To: Recovery Tucson <info@recoverytucson.org>' . "\r\n";
      
        $MailHeader .= 'From: <'. $_POST['Email'] .'>' . "\r\n";
                
                $MailBody .= '</html></body>';
        
        if ( !mail($MailTo, $MailSubject, $MailBody, $MailHeader) )
        {
                return false;
        }
        
        return true;
}

I think the problem is with sendmail when I run a ps aux |grep sendmail this is what Im getting. so it looks like it's trying to process but getting stuck on sending the mail out and im not too sure why.

 

bash-3.1$ ps aux |grep sendmail
root      3229  0.0  0.0   7020  2116 ?        Ss   11:57   0:00 sendmail: accepting connections       
smmsp     3232  0.0  0.0   6660  1668 ?        Ss   11:57   0:00 sendmail: Queue runner@00:25:00 for /var/spool/clientmqueue
root      3820  0.0  0.1   7512  3324 ?        S    13:12   0:00 sendmail: ./o36Jlk6Z003730 alt4.gmail-smtp-in.l.google.com.: user open
root      3901  0.0  0.1   7612  3200 ?        Ss   13:22   0:00 sendmail: ./o36KMeqM003899 alt2.gmail-smtp-in.l.google.com.: user open
mark      3966  0.0  0.0   2208   640 pts/0    R+   13:31   0:00 grep sendmail
bash-3.1$

It looks like process.php immediately redirects under all conditions. Also, I can't see any code in process.php to actually process the data posted to it from registration.php.

 

He is looping through the POST array. Also it is an if statement checking against the return value of the mailing function. These two things are fine.

It looks like process.php immediately redirects under all conditions. Also, I can't see any code in process.php to actually process the data posted to it from registration.php.

 

He is looping through the POST array. Also it is an if statement checking against the return value of the mailing function. These two things are fine.

 

correct everything was working fine, until I switched from Ubuntu to slackware 13 because Ubuntu is just way to bloated.

what exactly is it doing? I can't access your site.

 

what happens when you try to view the site

 

The site just freezes. I only allowed it like 30 seconds loading time but it didn't go anywhere. I am at work so it's not good for me to keep random sites just sitting on my computer lol.

what exactly is it doing? I can't access your site.

 

what happens when you try to view the site

 

The site just freezes. I only allowed it like 30 seconds loading time but it didn't go anywhere. I am at work so it's not good for me to keep random sites just sitting on my computer lol.

 

Gotcha, it's all pointing now to the sendmail for some reason I have 8 messages in mailq that aren't sending and according to /var/log/maillog it's all timing out im not too sure what's going on now, like I said it all use to work fine when I was running ubuntu now that im running slackware it's having issues.

what exactly is it doing? I can't access your site.

 

what happens when you try to view the site

 

The site just freezes. I only allowed it like 30 seconds loading time but it didn't go anywhere. I am at work so it's not good for me to keep random sites just sitting on my computer lol.

 

Gotcha, it's all pointing now to the sendmail for some reason I have 8 messages in mailq that aren't sending and according to /var/log/maillog it's all timing out im not too sure what's going on now, like I said it all use to work fine when I was running ubuntu now that im running slackware it's having issues.

 

Sorry I can't help you anymore. I'm not a Linux expert so I don't know what would cause it. My advice would be to google something on the mail function compared with the two operating systems while you wait for someone else to come along. It could be the way the mail server is set up as well.

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.