Foros del Web » Programando para Internet » Javascript »

alert con valor de input dinamico

Estas en el tema de alert con valor de input dinamico en el foro de Javascript en Foros del Web. hola a todos, necesito de su ayuda, tengo un formulario donde el usuario puede agregar mas inputbox, y textarea, y si los agrega pero necesito ...
  #1 (permalink)  
Antiguo 24/06/2015, 09:07
Avatar de rachpts  
Fecha de Ingreso: febrero-2012
Mensajes: 117
Antigüedad: 12 años, 2 meses
Puntos: 0
alert con valor de input dinamico

hola a todos, necesito de su ayuda, tengo un formulario donde el usuario puede agregar mas inputbox, y textarea, y si los agrega pero necesito que una vez pulsado el boton, me mande a la función javascript, y en esta me mande su valor con un alert

mi formulario es este

Código HTML:
 <div class="content">
					
					<div class="accordion odd">
					  <h3>1.1	Project Description and Scope of Work</h3>
					  <div class="content">
						Describe in detail the Project associated with the MOP, and the service scope of work. Example: This document includes different scopes 
						and/or scenarios in the service Z for equipment AB, and Application Y.  This MOP applies to Extension ONLY.
						<div class="col-sm-10">
								<textarea class="form-control" rows="5" id="wysiwig_simple1" name="ovinf1"></textarea>
						</div>
					  </div>
					</div>
					<div class="accordion odd">
					  <h3>1.2	Service Impact</h3>
					  <div class="content">
						Describe the impact as a result of performing this activity, including the impact in case of performing a rollback as part of the general MOP
						<div class="col-sm-10">
								<textarea class="form-control" rows="5" id="wysiwig_simple2" name="ovinf2"></textarea>
						</div>
					  </div>
					</div>
					<div class="accordion odd">
					  <h3>1.3	Generic MOP Correlation</h3>
					  <div class="content">
						This section contains links to the generic method of procedures that are related to the activity stated on this document. Those correlations apply for the previous and/or post related activities.
						<table class="table table-striped table-bordered table-hover table-heading no-border-bottom" id="field_grid">
							<thead>
								<tr>
									<th>MOP Name (Link)</th>
								</tr>
							</thead>
							<tbody>
								<tr>
									<td> <input type="text" value="" id="o1[]"  name="o1[]" placeholder="link" class="form-control" /></td>
									
								</tr>
							</tbody>
						</table>
						<button id="add_field" class="btn btn-default">Add Field <i class="fa fa-plus"></i></button>
						<script type="text/template" id="template">
								 <tr>
									<td>
										<input type="text" class="form-control" value="" id="o1[]"   name="o1[]" placeholder="link" />
									</td>
									
									<td>
										<a href="#" class="btn-remove"><li class="fa fa-trash-o"> </li></a>
									</td>
								</tr>
						</script>
					  </div>
					</div>
					<div class="accordion odd">
					  <h3>1.4	Specific MOP Correlation</h3>
					  <div class="content">
						This section contains links to the method of procedures that are related to the activity stated on this document. Those correlations apply for the previous and/or post related activities.
						<table class="table table-striped table-bordered table-hover table-heading no-border-bottom" id="field_grid2">
							<thead>
								<tr>
									<th>MOP Name (Link)</th>
								</tr>
							</thead>
							<tbody>
								<tr>
									<td> <input type="text" value=""  name="o2[]" placeholder="link" class="form-control" /></td>
									
								</tr>
							</tbody>
						</table>
						<button id="add_field2" class="btn btn-default">Add Field <i class="fa fa-plus"></i></button>
						<script type="text/template2" id="template2">
								 <tr>
									<td>
										<input type="text" class="form-control" value=""  name="o2[]" placeholder="link" />
									</td>
									
									<td>
										<a href="#" class="btn-remove2"><li class="fa fa-trash-o"> </li></a>
									</td>
								</tr>
						</script>
					  </div>
					</div>
					<button  onclick="saveovinf()">Save Overall Information &raquo;</button>
					<pre id="valores"></pre>
					 <div class="progress">
						<div class="progress-bar" role="progressbar" id="progressbar" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100" style="width: 0%;"><span class="sr-only">100% Complete</span></div>
					</div>
				  </div> 

Etiquetas: input, valor
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 23:41.