Ver Mensaje Individual
  #1 (permalink)  
Antiguo 08/10/2010, 16:24
oscarbt
 
Fecha de Ingreso: abril-2009
Ubicación: Colombia
Mensajes: 949
Antigüedad: 15 años
Puntos: 27
Cambiar color a resultado en en una caja de texto

Buenas, la verdad muy poco trabajo CSS, pero me gustaria saber como puedo hacer esto:
Tengo un formularo donde el usuario me ingresa el valor del lado de un cuadrado y en dos cajas te texto que estan deshabilidatas (disable), imprimo los resultados
Pero resulta que los resultados me salen en color negro y muy claritos,

Como puedo cambiar el color de esos resultados?.....O dejarlos mas oscuros?? eso se hace con CSS?...

Aca el codigo de mi formulario:

Código HTML:
Ver original
  1. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  2. <title>Cuadrado</title>
  3. <script languaje="JavaScript">
  4.  
  5. function num(c){
  6.  c.value=c.value.replace(/[A-z-\/\*\+]/, '');
  7. }
  8.  
  9.      
  10.  
  11.  
  12. <script languaje="JavaScript">
  13.           function area()
  14.          {
  15.             lado=document.datos.lado.value;
  16.    
  17.                          document.datos.perimetro.value=lado*4;
  18.              document.datos.resultado.value=lado*lado;
  19.          
  20.          }  
  21.       </script>
  22. <style type="text/css">
  23. <!--
  24. .Estilo1 {color: #0000FF}
  25. -->
  26. </head>
  27.  
  28. <br>
  29. <center><h1><b>CALCULO DE AREA DE UN CUADRADO</b></h1></center>
  30. <br />
  31. <hr />
  32.  
  33. <br>
  34. <br>
  35.  
  36.  
  37. <form name="datos">
  38. <center>
  39. <table width="500
  40. " border="1" >
  41.   <tr>
  42.     <td width="147"><div align="center"><strong><h2 class="Estilo1">INGRESO DE DATOS</h2>
  43.     </strong></div></td>
  44.     <td width="173"><div align="center">
  45.       <h2><strong><span class="Estilo1">RESULTADO</span></strong></h2>
  46.     </div></td>
  47.     <td width="173"><div align="center">
  48.       <h2><strong><span class="Estilo1">FIGURA</span></strong></h2>
  49.     </div></td>
  50.   </tr>
  51.   <tr>
  52.     <td><div align="center"><h3>VALOR DEL LADO </h3>
  53. <input  type="text" name="lado" size="10" onBlur="num(this);" onKeyPress="num(this);" onKeyUp="num(this);" /></div></td>
  54.     <td><div align="center">
  55. <h3>VALOR PERIMETRO </h3>
  56. <input type="text" name="perimetro" disabled="disabled">
  57.  
  58.   <h3>VALOR AREA </h3>
  59. <input type="text" name="resultado" disabled="disabled"></div><br></td>
  60. <td><div align="center">
  61. <h3><img src="Imagenes/cuadrado.jpg" alt="Cuadrado" > &nbsp;</h3>
  62. </div>
  63. <br></td>
  64.   </tr>
  65. </center>
  66.  
  67.  
  68.  
  69.   <br>
  70.    
  71.    <CENTER> <input type="button" value="Calcular valores" onClick="area()"> <input name="Limpiar"  type="reset" id="Limpiar" value="Borrar valores ingresados "></CENTER>
  72. </form>
  73. <br />
  74.  
  75. </body>
  76.  </html>

Agradezco me puedan colaborar