开发者

Get content of the page given by an URL thru Javascript

Does anybody here solved a similar problem?

I have a link that contains nothing but another link.

For example, given a URL lets say it is www.abc123proxy.info. And then that URL contains another URL on its page (yeah, just text) lets say th开发者_运维问答e URL for this one is www.masked-url.com?token=231940812093810. I need go to the second URL but I only have the first URL.

This is what I want to happen:

$(document).ready(function() {window.location = 'www.abc123proxy.info';});
// But I wanted to go to the link inside the page of that URL.

Is this problem can be solve using javascript? I'm open for other better solution if you have.

Thanks!


$.ajax({
        url:'first_url',
        type:'get',
        success:function(data){
          var _newUrl=$(data).find('a:first');
        }
})
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜