martes, 22 de agosto de 2017

PROYECTO (con tablas)

resultado.php

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>barajas_04_10a</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<style type="text/css" media="all">
@import "images/style.css";
</style>
</head>
<body>

<div class="content">
  <div id="header">
    <div class="title">
      <h1>Proyecto</h1>
      <h3>2017</h3>
    </div>
  </div>
  <div id="main">
    <div class="center">
      <h2><a href="#">Resultado</a></h2>
      <p>
    <br><br>
    <?php
$numero =$_POST['numero'];
$funcion =$_POST['funcion'];




/*if ($funcion == "seno"){
   echo "<font color='#330033'><h2>Seno</h2></font>";
    }
 
   else{

    if($funcion == "coseno"){
      echo "<font color='#330033'><h2>Coseno</h2></font>";
     }
     else{

      if($funcion == "tangente"){
        echo "<font color='#330033'><h2>Tangente</h2></font>";

       }

       else{

        if($funcion == "arco_de_tangente"){
          echo "<font color='#330033'><h2>Arco de Tangente</h2></font>";
         }

         else{

          if($funcion == "tangente_hiperbolica"){

            echo "<font color='#330033'><h2>Tangente Hiperbolica</h2></font>";
            }
         
          else{

            echo "<font color='#330033'><h2>Raiz Cuadrada</h2></font>";


              }


              }



            }

          }
       
        }


echo "<br>";*/





 
   if ($funcion == "seno"){

    $name="Seno";
     $rta="<u>Rta</u>: ".(sin($numero));

   }
   else{

    if($funcion == "coseno"){

      $name="Coseno";
      $rta="<u>Rta</u>: ".(cos($numero));
     }
     else{


      if($funcion == "tangente"){

        $name="Tangente";
        $rta="<u>Rta</u>: ".(tan($numero));

       }

       else{

        if($funcion == "arco_de_tangente"){

          $name="Arco de Tangente";
          $rta="<u>Rta</u>: ".(atan($numero));
         }

         else{

          if($funcion == "tangente_hiperbolica"){

            $name="Tangente Hiperbolica";
            $rta="<u>Rta</u>: ".(tanh($numero));


          }
          else{ //echo(sqrt($numero));

            if($funcion == "raiz_cuadrada" && $numero>=0){

              $name="Raiz Cuadrada";
              $rta="<u>Rta</u>: ".(sqrt($numero));

            }

              else{
                $validar=($numero*(-1));

                $name="Raiz Cuadrada";
                $rta="<u>Rta</u>: "."Raiz imaginaria de ".$numero." es: ".(sqrt($validar));
              }

              }


              }



            }





          }






         }


echo "<table height:'300px'>";

echo "<tr >";
echo "<td>";
echo "<font color='#330033' size='6'>".$name."</font>"."<br>";
echo "</td>";
echo "</tr>";

echo "<tr>";
echo "<td>";
echo  "<br>".$rta;
echo "</td>";
echo "</tr>";

echo "</table>";



  ?>

     </p>
      <br />
   
      <br />
    </div>
    <div class="leftmenu">
      <div class="nav">
        <ul>
         <li><a href="index.php">Inicio</a></li>
          <li><a href="resultado.php">Resultado</a></li>
          <li><a href="derechos.php">Derechos</a></li>
        </ul>
      </div>
    </div>
  </div>
  <div id="prefooter">
   
  </div>
  <div id="footer">
    <div class="padding"> Copyright &copy; 2006 Your Site Name | Design: <a href="http://www.free-css-templates.com">David Herreman </a> | <a href="#">Contact</a> | <a href="http://jigsaw.w3.org/css-validator/check/referer">CSS</a> and <a href="http://validator.w3.org/check?uri=referer">XHTML</a> | <a href="http://www.solucija.com">Solucija.com</a> | <a href="#">Login</a> </div>
  </div>
</div>
</body>
</html>


NOTA: index.php y derechos.php quedan exactamente igual.

CLICK AQUÍ PARA DESCARGAR LA CARPETA CON TODOS LOS ARCHIVOS!!!

No hay comentarios:

Publicar un comentario