Fast solution: In Javascritp you can do this: element = document.getElementById("myinput"); window.open("http://127.0.0.1:8000/consulta/?consulta="+element.value, "MsgWindow", "width=200, height=100");
but continue reading Are you use ajax? If the answer is not, then see https://github.com/yceruto/django-ajax. A concept problem is there, modal is a interface view (in the browser) and your method refresh the page (It is a GET Request). I don't know what kind of framework you are using, but in general you can do something like this: <div id="mymodal" class="modal"> Operadora Tipo CLARO MOVEL </div> <script> $("#mymodal").modal(); </script> for more information see http://getbootstrap.com/javascript/#modals http://jqueryui.com/dialog/ PD: You can do better implementation if you are using django ajax 2015-02-26 13:08 GMT-06:00 Emerson Luiz <elui...@gmail.com>: > Hi, > > I have the following problem: > > I need to set up a form, that when the OK button is clicked, it passes a > parameter and open a modal with the result. > Today the query works as follows: > > http://127.0.0.1:8000/consulta/?consulta=3188888888 > > The 3188888888 is the parameter. > > return: > > Operadora TipoCLAROMOVEL > > > > Thanks > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to django-users+unsubscr...@googlegroups.com. > To post to this group, send email to django-users@googlegroups.com. > Visit this group at http://groups.google.com/group/django-users. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-users/9f8e5cbb-45a0-464d-9047-6ccfdc0a4757%40googlegroups.com > <https://groups.google.com/d/msgid/django-users/9f8e5cbb-45a0-464d-9047-6ccfdc0a4757%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- "La utopĂa sirve para caminar" Fernando Birri -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAG%2B5VyMbtAjJH30MYDMe4S1M%2Bdfo7w7gGB8SSc%3DrJBqaZFxaNg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.