Jump to content
  • Revista PROGRAMAR: Já está disponível a edição #60 da revista programar. Faz já o download aqui!

Sign in to follow this  
Daniela C

está em função?

Recommended Posts

Daniela C

<html>

<body>

Soma</br><br>

<form method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>">

primeiro valor: <input type="text" name="valor1"></br><br>

segundo valor: <input type="text" name="valor2"></br><br>

<input type="submit" value="calcular">

</form>

<?php

$valor1=$_POST["valor1"];

$valor2=$_POST["valor2"];

$soma=$valor1+$valor2;

echo "O valor da soma é ".$soma;

?>

</body>

</html>

está declarado como uma função php?

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.