Make a post on an external url

0

They put me in a project that was made in ASP.NET MVC 2 and need to be integrated with Itaú Shopline, I downloaded the Itall dll, I did all the encryption procedures, I can generate the data, but at the time of sending to the external URL the post returns to the server of the site and not to the url of itaú, which makes all sense, then in that part that enters my doubt.

How do I post to an external url and submit the information I need?

Here is the code that is given as an example in the Itaú documentation:

    <FORM ACTION=”https://shopline.itau.com.br/shopline/shopline.aspx”method=”post”
name=”form1” target=”SHOPLINE”>
     <INPUT type=”hidden”name=”DC”value=”<%= dados %>”>
<br>
     <INPUT type=”submit”name=”Shopline”value=”Itaú Shopline”>
</form>

Hugs!

    
asked by anonymous 21.10.2016 / 13:15

1 answer

0

Hello, I do not know if this is what you are looking for, but it might help.

DE:

<INPUT type=”submit”name=”Shopline”value=”Itaú Shopline”>

To:

<input type="button" name="Shopline" id="Shopline" value"Itau Shopline">

So in JS with Jquery

$("#Shopline").click(function(){
$.post(
     "Sua URL", 
      function(){
          //trata retorno
      })
})

See these links: link

    
21.10.2016 / 18:11