Hi folks,
Well, finally decided to get my feet wet on PHP. But now need a bit of help.
I read about the IF statement and giving it a shot. What I'm trying to do now
is figure out what's the code to do something like this:
1. There's an empty box to fill in with the words like "please enter figure", and
click submit.
2. The code will give a result like "you pay 1% tax" if the figure that's entered
is within a certain range, say, 5,000 to 10,000.
What I can't figure out using the IF statement is what do I put in that'll take
in the figure (like 6,000) and see if it's within a certain numeric range like I've
posted from item 2 above. So far I'm gathering it's something like this below:
Or something like that. Been racking my brain for the past hour and feel like I
am going on overload.
Any help?
Well, finally decided to get my feet wet on PHP. But now need a bit of help.
I read about the IF statement and giving it a shot. What I'm trying to do now
is figure out what's the code to do something like this:
1. There's an empty box to fill in with the words like "please enter figure", and
click submit.
2. The code will give a result like "you pay 1% tax" if the figure that's entered
is within a certain range, say, 5,000 to 10,000.
What I can't figure out using the IF statement is what do I put in that'll take
in the figure (like 6,000) and see if it's within a certain numeric range like I've
posted from item 2 above. So far I'm gathering it's something like this below:
if ($figure == 5,000 to 10,000) {
echo "You pay 1% tax";
}
Or something like that. Been racking my brain for the past hour and feel like I
am going on overload.
Any help?












