Jump to content

Search the Community

Showing results for tags 'form handiling'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 1 result

  1. Hi, I need tips and sugestions for form that I crated, just basic stuff. Also there is couple things that I need to do: 1) when submitted, form should to print message that form is sent, or if something is not ok, to display error mesage, everything on same page example, contact.php 2) now, when form is sent I recive it on email, but feedback field, textarea give me html tags for new line and something like that here is the code, please help: <?php if(empty($_POST["name"])) { die("Please provide valid name"); } ?> <?php if(is_numeric($_POST["name"])) { die("Please provide valid name"); } ?> <?php $email = $_POST["email"]; if (!preg_match("/([\w\-]+\@[\w\-]+\.[\w\-]+)/",$email)) { die("E-mail address not valid"); }; ?> <?php if(empty($_POST["subject"])) { die("Plese enter a subject."); } ?> <?php if(!isset($_POST['submit'])) { $ToEmail = 'xxx@yahoo.com'; $EmailSubject = 'Pitanje sa xxx.com'; $mailheader = "From :". $_POST["email"]. "\r\n"; $mailheader .= "Reply to :". $_POST["email"]. "\r\n"; $mailheader .= "Ova poruka sadrzi pitanje postavljeno na www.xxxx.com \r\n"; $MESSAGE_BODY = "Ime : " .$_POST["name"]." \r\n"; $MESSAGE_BODY .= "Email : " .nl2br($_POST["email"])." \r\n"; $MESSAGE_BODY .= "Naslov : " .$_POST["subject"]." \r\n"; $MESSAGE_BODY .= "Poruka : " .nl2br($_POST["feedback"])." \r\n"; mail($ToEmail, $EmailSubject, $MESSAGE_BODY, $mailheader) or die ("Failure"); echo "Vasa poruka je uspjesno poslana! Kliknite <a href=\"index.html\">ovde</a> za pocetnu stranu "; }; ?>
×
×
  • 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.