Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - PHP WEB FORM SCRIPT
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Topic ClosedPHP WEB FORM SCRIPT

 Post Reply Post Reply Page  12>
Author
gupta_ji View Drop Down
Groupie
Groupie
Avatar

Joined: 29 October 2003
Location: India
Status: Offline
Points: 70
Direct Link To This Post Topic: PHP WEB FORM SCRIPT
    Posted: 07 July 2004 at 3:25pm

I need a form script made in PHP. As I have made one of my site www.brigadeindia.com in PHP but the query form at http://www.brigadeindia.com/query.php is not working right now. Further, on http://www.brigadeindia.com/contactus.php I have used one flash file but it is not being shown. I donot know the reason why. Actually I am not good in PHP. I know only ASP. So, Please help.

Thanks



Edited by gupta_ji
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Direct Link To This Post Posted: 07 July 2004 at 3:39pm
You probably won't get much of a response on this forum as most people on this forum only know ASP/.NET
Back to Top
zMaestro View Drop Down
Senior Member
Senior Member


Joined: 11 May 2003
Location: Egypt
Status: Offline
Points: 1183
Direct Link To This Post Posted: 10 July 2004 at 1:27pm
Originally posted by gupta_ji gupta_ji wrote:

Actually I am not good in PHP. I know only ASP. So, Please help.

what forces you to use PHP.. this forum is free btw

anyway... here you are:

http://www.hotscripts.com/PHP/Scripts_and_Programs/Discussio n_Boards/index.html

Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Direct Link To This Post Posted: 10 July 2004 at 1:28pm
He wants a form script not a forum script
Back to Top
zMaestro View Drop Down
Senior Member
Senior Member


Joined: 11 May 2003
Location: Egypt
Status: Offline
Points: 1183
Direct Link To This Post Posted: 12 July 2004 at 1:32pm

Originally posted by Mart Mart wrote:

He wants a form script not a forum script

Ooops

Back to Top
zMaestro View Drop Down
Senior Member
Senior Member


Joined: 11 May 2003
Location: Egypt
Status: Offline
Points: 1183
Direct Link To This Post Posted: 12 July 2004 at 1:46pm

if form = contact form.. this may help

<?php
//if else statment to process the form
 //if sfeedback returns true
if($email != "") {
  //if the email address is correct format
  if(eregi("([[:alnum:]\.\-]+)(\@[[:alnum:]\.\-]+\.+)", $email)) {
   //inserts header
    print $head;
?>
<!-- Confirms the information you sent as feedback -->
    Thanks for your Rates Request Submission, <?php echo $name ?>. Here is what you submission:<br>
Name: <?php echo $name ?><br>
Email: <?php echo $email ?><br>
Feedback: <?php echo $feedback ?><br>
<?php
 //sets veriables for the email to webmaster
    $subject = "Feedback from your site";
// Change the following line to your email address
    $sendto = "Sales_Marketing@egyvision.com";
    $header = "From: $email";
 //mail() to send the info to webmaster
    mail($sendto, $subject, $feedback, $header);
    print "Thank you.  Your comments have been sent to the Desert Rose - You will be recieving the Rates in Several Hours\n";
 print "<p><p>";
 //prints footer
    print $tail;
 //exits script so the form is not put up again
    exit();
 //if address doesnt' look right error message
 } else { print"<center><font color=ff0000>!!The address $email doesn't look right, check it and try again!!</font></center>";
 }
}
//if the above if else statement came back false the following would be printed
//header
echo $head;

// you may need to remove printing the header
?>
<!--Change greeting if you like-->

<form action="<?php echo $PHP_SELF ?>" method="POST">
<tr><td><b>Name</td>
<td> <input type="text" name="name" size="20" /></td></tr>

<tr><td><b>email</td>
<td> <input type="text" name="email" size="20" /></td></tr>

<tr><td><b>feedback</td>
<td> <input type="text" name="feedback" size="20" /></td></tr>

<tr><td><b>&nbsp;</td>
<th><input type="submit" name="submit" value=" Send ">          <input type="reset" name="reset" value=" Clear "></th></tr>
</form>



Edited by zMaestro
Back to Top
gupta_ji View Drop Down
Groupie
Groupie
Avatar

Joined: 29 October 2003
Location: India
Status: Offline
Points: 70
Direct Link To This Post Posted: 13 July 2004 at 10:33am

Originally posted by zMaestro zMaestro wrote:

what forces you to use PHP.. this forum is free btw

Linux Forces me to use PHP.

Thanks for the code you gave me. If you can see my query form at www.brigadeindia.com/query.php you will find a lot of fields than single feedback field. The script you gave I also got from serveral links on the net. The problem I m getting is that there are more than one field, how should i get all the fields in this code. Hope this clears my point.

The other problem i m getting is that I am unable to see my flash file on my contact us page. Can we use flash file in PHP. if yes, what is the code. is that different from ASP code.

Thanks

Back to Top
zMaestro View Drop Down
Senior Member
Senior Member


Joined: 11 May 2003
Location: Egypt
Status: Offline
Points: 1183
Direct Link To This Post Posted: 16 July 2004 at 2:35am
Originally posted by gupta_ji gupta_ji wrote:

Originally posted by zMaestro zMaestro wrote:

what forces you to use PHP.. this forum is free btw

Linux Forces me to use PHP.

What forces you to host on Linux

Back to Top
 Post Reply Post Reply Page  12>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.