Jump to content


Photo

If...Else elseif w/Forms


  • Please log in to reply
2 replies to this topic

#1 jwk811

jwk811
  • Members
  • PipPipPip
  • Advanced Member
  • 714 posts

Posted 26 September 2006 - 12:49 AM

How do I make the forms being submitted to have a different action depending on what was submitted? I know you're supposed to use the elseif statment for it but I'm not sure how.. could someone give me an example or some script? Thanks!

#2 Tandem

Tandem
  • Members
  • PipPipPip
  • Advanced Member
  • 251 posts

Posted 26 September 2006 - 12:53 AM

$blah = $_POST['blah'];

if ($blah > 6) {
$action = "something";
}

else if ($blah < 7) {
$action = "nothing";
}


You mean something like that?

#3 jwk811

jwk811
  • Members
  • PipPipPip
  • Advanced Member
  • 714 posts

Posted 26 September 2006 - 01:28 AM

yeah i think so, thanks ill try that out




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users