PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming LanguagesPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old December 7th, 2012, 04:19 AM
philippo21 philippo21 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2012
Posts: 1 philippo21 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 12 m 22 sec
Reputation Power: 0
PHP-General - Contact.php not found. Server issue?

Hello,

I am not very familiar with php unfortunately.

I am trying to set up a contact form: uebersee.com.sg/contact.html

But my server doesn't find the respective contact.php ("Nothing found for contact Php)"

This is the server:
Server: Localhost via UNIX socket Server version: 5.5.27-cll Protocol version: 10

Does anyone have an idea what's missing or what I do wrong?

Thanks so much!

Philipp


PHP Code:
<?php

    
// Enter your e-mail address.
    
$to 'name@name.com';

    
// Go to your-site.com/contact.php?test to send a testing email.
    
if ( isset($_GET['test']) ) {
       
mail($to'Message from contact form''It\'s working!''From: ' $to "\r\n");
       die(
'Testing e-mail has been sent.');
    }

    
// Validate e-mail.
    
function isValidEmail$email null ) {
       return 
preg_match"/^
          [\d\w\/+!=#|$?%{^&}*`'~-]
          [\d\w\/\.+!=#|$?%{^&}*`'~-]*@
          [A-Z0-9]
          [A-Z0-9.-]{0,61}
          [A-Z0-9]\.
          [A-Z]{2,6}$/ix"
$email
       
);
    }

    
// Validate input.
    
if ( !empty($_POST['name']) && isValidEmail($_POST['email']) && !empty($_POST['text'])) {
       
       
// Set e-mail headers.
       
$message $_POST['text'];
       
$headers 'From: ' $_POST['name'] . ' <' $_POST['email'] . '>' "\r\n" 'Reply-To: ' $_POST['email'];
       
       
// Send e-mail.
       
if ( mail($to'Message from contact form'$message$headers) ) echo 'sent';
       
    } else {

       echo 
'invalid';

    }
    
?>

Reply With Quote
  #2  
Old December 7th, 2012, 07:01 AM
gw1500se gw1500se is offline
Contributing User
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: Jul 2003
Posts: 2,886 gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level)gw1500se User rank is Colonel (50000 - 60000 Reputation Level) 
Time spent in forums: 1 Year 2 Weeks 3 Days 8 h 22 m 27 sec
Reputation Power: 581
This is not a PHP issue. Assuming contact.php is the code you posted then it means wherever you put it is not in documentroot or the url is wrong. Make sure the URL is correct with respect to documentroot and that you have contact.php in that path.
__________________
There are 10 kinds of people in the world. Those that understand binary and those that don't.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPHP Development > PHP-General - Contact.php not found. Server issue?

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap