Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource


Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


                <div class="container">
<a class="navbar-brand" href="{{ url('/home') }}">Menu principal</a>
    <div class="row justify-content-center">
        <div class="col-md-8">
            <div class="card">
                <div class="card-header">Invertir</div>

                <div class="card-body">
                    <div class="col-md-4 form-group">
                        <div class="form-group">
                                <label><p class="text-secondary"> <b>Proyecto:</b> {{ $proyecto->nombre_pro }} </p></label>          
                                <label><p class="text-secondary"> <b>Descripción:</b> {{ $proyecto->descripcion }} </p></label>          
                                <label><p class="text-secondary"> <b>Monto solicitado:</b> {{ $proyecto->montosol }} USD</p></label>          
                                <label><p class="text-secondary"> <b>Tasa:</b> {{ $proyecto->tasa }} %</p></label>                      
                                <label><p class="text-secondary"> <b>Período:</b> Cada {{ $proyecto->periodo/30 }} Mes(es)</p></label>              
                                <label><p class="text-secondary"> <b>Plazo</b> {{ $proyecto->plazo }} Mes(es) </p></label>                     
                  <div class="col-md-3 form-group">
                    <label for="exampleInputEmail1">Monto disponible para invertir</label>
                    <input type="text" class="form-control" aria-describedby="emailHelp" value="{{$montosol}}" readonly>
                  <div class="col-md-3 form-group">
                    <label for="exampleInputEmail1">Tu inversion actual en este proyecto</label>
                    <input type="text" class="form-control" aria-describedby="emailHelp" value="{{$totalinversion}}" readonly>
                  <form action="{{ url('montoinv') }}" method="POST">
                  <div class="form-group row">
                      <label class="col-md-4 col-form-label text-md-right" for="exampleFormControlSelect1">Seleccione una opcion (recomendable probar el monto antes de invertir)</label>
                      <div class="col-md-6">
                      <select class="form-control" id="exampleFormControlSelect1">
                        <option value="">----</option>
                        <option value="1">Probar</option>
                        <option value="2">Invertir</option>
                  <div class="col-md-5 form-group">
                    <h2><label for="exampleInputEmail1">Monto a invertir</label></h2>
                  <input type="number" class="form-control" name= "montoinv"  aria-describedby="emailHelp" placeholder="" min="100" max="{{ $proyecto->montosol }}" required>
                  <span style="font-size:12px; font-style: italic;">Digite el monto a invertir expresado en (USD)</span>
                  <input type="hidden" name="idpro" value="{{ $proyecto->id_pro }}">
                  <div class="col-md-5 form-group">
                  <button type="submit" name="btn" value="probar" class="btn btn_1">Probar</button>
                  <button type="submit" name="btn" value="invertir" class="btn btn_2">Invertir</button>
                  @if (isset($probar))
                  <table class="table">
                        <th scope="col">#</th>
                       <!-- <th scope="col">Username</th>-->
                        <th scope="col">Interes</th>
                        <th scope="col">Capital</th>
                        <th scope="col">Cuota </th>
                        <th scope="col">Saldo</th>
                      <td>{{ $e+1 }}</td>
                      <td>{{ number_format($i[$e],0) }}</td>
                      <td>{{ number_format($ca[$e],0) }}</td>
                      <td>{{ number_format($cu[$e],0) }}</td>
                      <td>{{ number_format($s[$e],0) }}</td>



  .visible {
      display: inline-block;


                let botones = document.querySelectorAll("button");

//cada vez que el valor del select cambia
  //recupera el valor de la opción seleccionada
  let valorSeleccionado = exampleFormControlSelect1.options[exampleFormControlSelect1.selectedIndex].value;
  // para todos los botones elimina la clese visible
  botones.forEach(b =>{b.classList.remove("visible")})
  //selecciona el boton que tiene que ser visible
  let elBoton = document.querySelector(`.btn_${valorSeleccionado}`)
  //y si el boton existe
  //y le añade la clase visible