using document.getElementById to get input values in the url

738 Views Asked by At

Below is my code.

<input type="submit" class="thickbox btn btn-large btn-darkbrown" value="Prüfen" onclick="tb_show('https://ibe.dirs21.de/Channels/bayers-hotel/default.aspx?anreise='+document.getElementById('anreise').value+'&abreise='+document.getElementById('abreise').value+'&adults='+document.getElementById('adults').value+'&children=1'+document.getElementById('children').value+'&TB_iframe=true&height=800&width=800&modal=true')"

Issue:- If i click on submit, then the thickbox shows the same site and not the url.

1

There are 1 best solutions below

0
Farbod On

I modified the code now to this:

<input type="button" class="btn btn-large btn-darkbrown" value="Prüfen" onclick="tb_show('Zimmer','https://ibe.dirs21.de/Channels/bayers-hotel/default.aspxTB_iframe=true&height=800&width=800')">

It works, but how can i integrate the Values from the inputfields now?