I finally got up and running with jerdo's help. I'm using apache, php on win xp. I have greated my first couple of scripts and they worked well. But pass variables from a form they are not recognised. I have tried both the post and get methods, checked the names are ok and even used code that I know works for others. So I guess it must be my configuration? or extensions. I only done what was require to get the basics working. I 've used the Binary version of php4. Can anyone help?
below are the files 2 I used:
oh, and is there a way to edit php files after I save them in notepad as .php?
file "loan.php"
<html>
<head>
<title>"You Better Pay Up" Loan Services</title>
</head>
<body>
<center>
<h3>Welcome to "You Better Pay Up" Loan Services</h3>
You pay us ten percent every week, or else.
<form action="loanshark.php" method=post>
My hovercraft costs $<input type="text" name="cost">
<p><input type="submit" name="submit" value="What's My Interest Payment?">
</form>
</center>
</body>
</html>
file "loanshark.php"
<html>
<head>
<title>Loanshark</title>
</head>
<body>
<?php
$interest_rate = .14;
function YouOweMe($cost, $interest_rate) {
$weekly_payment = ($cost*$interest_rate);
print "You better pay me \$$weekly_payment every week, or else!";
}
YouOweMe($cost, $interest_rate);
?>
</body>
</html>