| | |
help me find the error.
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
Thread Solved |
•
•
Join Date: Jan 2009
Posts: 4
Reputation:
Solved Threads: 0
Hi everyone, i've just studied basic PHP and i usually study online. I wite this code for contact form.But i cannot find error and fix it-Because i'm new :-). Please help me. Thank very much
php Syntax (Toggle Plain Text)
]<?php /* Subject and Email Variable*/ $emailSubject = 'Email from Clients'; $webMaster = 'tracyn2k2@yahoo.com'; /* Gathering Data Variables */ $nameField = $_POST['name']; $emailField = $_POST['email']; $phonenumberField = $_POST['phonenumber']; $commentsField = $_POST['comments']; $body = " From: $email\r\n Name: $name\r\n Phone number: $phonenumber\r\n Comments: $comments\r\n"; $success = mail($webMaster, $emailSubject, $body); /* Result sender */ echo (" <html> <head> <title>Untitled Document</title> <style type="text/css"> <!-- body { background-color: #000000; } .style1 { font-family: Arial, Helvetica, sans-serif; font-size: 0.7em; color: #FFFFFF; font-weight: bold; } a:link { text-decoration: none; color: #FFFF33; } a:visited { text-decoration: none; color: #FFFF33; } a:hover { text-decoration: none; color: #0066FF; } a:active { text-decoration: none; color: #0099FF; } --> </style></head> <body> <div id="content"><img src="images/banner.jpg" align="top"> <p> </p> <p class="style1"><a href="index.html">Back to Homepage </a></p> <p class="style1"> </p> <p class="style1">Dear Clients,</p> <p class="style1">Thank you for your inquiries. We will reply you within 24 hours.</p> <p class="style1"> </p> <p class="style1">Best Regards,</p> <p class="style1"> </p> <p class="style1">Fusion CyberWorks. </p> </div> </body> </html>"); ?>
Last edited by peter_budo; Jan 30th, 2009 at 2:15 pm. Reason: Keep It Organized - For easy readability, always wrap programming code within posts in [code] (code blocks) and [icode] (inline code) tags.
•
•
•
•
php Syntax (Toggle Plain Text)
echo (" <html> <head> <title>Untitled Document</title> <style type="text/css">
replace the dquotes in
<style type="text/css"> with single quotes or escape them.and check the rest of the script
<p class="style1" .These would show up (like above) if you had an editor with syntax highlighting, as do unclosed braces <div>without</div> etc
i use a notepad replacement(google) for that reason
Last edited by almostbob; Jan 28th, 2009 at 6:59 am.
Failure is not an option It's included free
If at first you dont succeed, join the club
Of course its always in the last place you look, you dont keep looking after you find it
Please mark solved problems, solved
If at first you dont succeed, join the club
Of course its always in the last place you look, you dont keep looking after you find it
Please mark solved problems, solved
![]() |
Similar Threads
- Please help me to find error in this program .I am trying to add data to a dynamic ar (C++)
- program error for cd burner program (Windows NT / 2000 / XP)
- runtime error#58 (Visual Basic 4 / 5 / 6)
- Can't find the error (C)
- help me find the error (C++)
- find out the error in my code (Java)
- Lotus notes error: #0c:04 (Networking Hardware Configuration)
- Bridge.dll error (Viruses, Spyware and other Nasties)
- iexplorer.exe send error reports(1 too many) (Web Browsers)
Other Threads in the PHP Forum
- Previous Thread: Can someone please help me with this!?
- Next Thread: Need your help
| Thread Tools | Search this Thread |
apache api array beginner binary broken cache cakephp checkbox class cms code confirm cron curl customizableitems database date display dynamic echo email error external fcc file files folder form forms forum freelancing function functions google header headmethod howtowriteathesis href htaccess html iframe image include insert ip javascript joomla limit link login mail malfunction menu method mlm mod_rewrite multiple mysql neutrality oop pageing pagerank paypal pdf php phpmysql play problem query question radio random recursion remote root script search select server sessions sms soap source space sql support! syntax system table template tutorial update upload url validator variable video web youtube






