Ciao, ho scaricato un javascript da html che tramite una select mi apre automaticamente dei link nel target che dico io (nel mio caso in un iframe nella stessa pagina). C' è, secondo voi, un modo per fare effettuare un redirect anche ricliccando su un link gia selezionato?
Il codice è questo
<script language="JavaScript">
var theTarget = "_blank";
function goThere(){
if(!document.theForm.theMenu.selectedIndex==""){
window.open(document.theForm.theMenu.options[document.theForm.theMenu.selectedIndex].value,theTarget,"");}}
</script>
<form name="theForm">
<select name="theMenu" size=1 onChange="goThere()">
<option selected value="">Your Title
<option value="http://www.html.it">HTML.it
<option value="http://freephp.html.it">FREEPHP
<option value="http://freeasp.html.it">FREEASP
<option value="http://freephp.html.it">FORUM
</select>
</form>
In pratica se scelgo freephp mi apre il link, se poi lo riscelgo non fa.