1
Well, I have a form and need when selecting a select option to change:
1 line - action
2 line - value
3 line - value
15 line - Change where this is written environmentOrca2 to for example environmentOrca1
<form id="formulario2" name="formulario2" method="post" enctype="multipart/form-data" action="mail-lista-de-descontos.php" >
<input type="hidden" name="acao" id="acao" value="enviaOrca2" />
<input type="hidden" name="mailTo" id="mailTo" value="[email protected]" />
<label>Email:</label>
<input type="email" name="email" id="email" data-required="1" data-title="E-mail" required>
<label>Dia:</label>
<select name="lista">
<option value="Sexta15abril">Sexta 15 de Abril</option>
<option value="Sábado16abril">Sábado 16 de Abril</option>
<option value="Sexta22abril">Sexta 22 de Abril</option>
<option value="Sábado23abril">Sábado 23 de Abril</option>
</select>
<label>Nomes Completos:</label>
<textarea name="mensagem" id="mensagem" data-required="1" data-title="Mensagem" placeholder="Exemplo: João da silva, Tenório Antonio" ></textarea>
<a href="javascript:enviaOrca2()" title="Enviar">Enviar</a>
</form>
The only solution I found was this below only I do not know how it does to change several options at the same time
<select id='seuSelect' onChange='alteraAction(this.value)' >
// seus options aqui, lembre-se, cada option deve ter um 'value'
</select>
function alteraAction(valor) {
if (valor == "Segunda Opção") {
$('#idFormulario').attr('action', 'novaaction.php');
}
}
Take a look @user4451 http://loudev.com/
– Wellington Silva Ribeiro
You want a pickList? take a look at my answer and see if it helps you: http://answall.com/questions/114804/como-cria-um-formul%C3%A1rio-de-associa%C3%A7%C3%A3o-picklist-em-modal/114832#114832
– Gabriel Rodrigues
Wellington Silva Ribeiro I joined this site but there the codes insert and remove from a container what I want is to change the text of some properties as action when I select an option in select, why each option of select goes to a different email
– user4451
Gabriel Rodrigues As I said to Willington I just want the text of certain form properties to change as I make a choice in select
– user4451