O
O
Oleg Galimov2018-01-28 15:00:40
JavaScript
Oleg Galimov, 2018-01-28 15:00:40

How to get xml data of two ajax requests from a link?

Good time of the day.
Tell me how to make two ajax requests to an external server from the form with a login and password,
the first request should catch e-mail

https://lk.webvm.ru/billmgr?authinfo='login':'password''&out=xml&func=user
$xml->elem as $info
$info->email;

and the second is the domain name
https://lk.webvm.ru/billmgr?authinfo='login':'password'&out=xml&func=domain

i tried to do this here
$('.bill_botton').click(function() {
      var login = $('#authLogin').val();
      var password = $('#authPassword').val();
    $.ajax({
    type: "POST",
    url: "https://lk.webvm.ru/billmgr?authinfo='login':'password''&out=xml&func=user",          
    dataType: "xml",
    success: function( data ){
    alert(data);
                    }
  });	
});

NOT how can I display the data.
Looking forward to the answers.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alibek Issakul, 2018-01-28
@Alibek-kz

Try

url: 'https://lk.webvm.ru/billmgr?authinfo=' + login + ':' + password + '&out=xml&func=user',

O
OKyJIucT, 2018-01-28
@OKyJIucT

url: "https://lk.webvm.ru/billmgr?authinfo='" + login + "':'" + password" + '&out=xml&func=user",

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question