i need to return an entire html page using an ajax call

Mohammed Ali Kachbouri

i need to return the content of this page http://service.semanticproxy.com/processurl/ftfu27m3k66dvc3r43bzfneh/html/http://www.smallbiztechnology.com/archive/2013/12/why-creating-a-digital-storefront-is-crucial-for-your-small-business.html but when i call this function

function getResult() {
            var url="http://service.semanticproxy.com/processurl/ftfu27m3k66dvc3r43bzfneh/html/http://www.smallbiztechnology.com/archive/2013/12/why-creating-a-digital-storefront-is-crucial-for-your-small-business.html";
            $.ajax({
                cache: true,
                url: url,
                success: function (result) {
                    alert(result);
                }
            });
        }

I got this in firebug:

segment.min.js (ligne 1) GET http://service.semanticproxy.com/processurl/ftfu...orefront-is-crucial-for-your-small-business.html 200 OK 379msA.

Any idea how i can get the content of that page?

Jentel

This code won't work for you. the reason is that the html page you are trying to retrieve is not a valid JAVASCRIPT file (and you also can't use jsonp because it is not returning any json string.)

Your solution is to use a server script (such as php:

<?Php print file_get_contents(url); ?> 

).

OR - if the website is yours , add a response to the script on request.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Ajax return full html page

From Dev

How to remove a specific tag from the entire html page using jsoup

From Dev

Unable to call Page Method using jQuery ajax

From Dev

Using ajax to call php and return multiple variables?

From Dev

How can call a page on submit using ajax?

From Dev

Need Help to load a html page using jquery

From Dev

Jquery Ajax call doesn't hit the action method/returns entire HTML page

From Dev

Need to redirect php page to html using htaccess

From Dev

Wordpress ajax call returns entire html page

From Dev

I need part of the page to be changed dynamically with ajax

From Dev

Ajax call return whole page instead of replacing a div tag

From Dev

Return html form field on AJAX call

From Dev

jQuery ajax call only from HTML page

From Dev

Return view after using ajax call

From Dev

How to return PHP response to HTML page using AJAX

From Dev

I have a piece of html/javascript that need to be opened in a new page, but I'm using Wix.com

From Dev

AJAX request returns entire HTML page instead of just the data I wanted it to echo

From Dev

How to remove a specific tag from the entire html page using jsoup

From Dev

Unable to call Page Method using jQuery ajax

From Dev

Populate html dropdown list using Ajax function call during page load

From Dev

Programming scrollbar (like volume control) in html page that produces call on update using php/javasctipt/ajax technologies

From Dev

I need jqgrid to refresh the entire page, not just the grid

From Dev

Jquery Ajax call doesn't hit the action method/returns entire HTML page

From Dev

I need part of the page to be changed dynamically with ajax

From Dev

Return view after using ajax call

From Dev

using Python, Flask and Ajax, how can I parse a response from an ajax call and print as HTML?

From Dev

How can I replace the entire HTML of a page, or its body content, via an AJAX call's success callback?

From Dev

Ajax Call using Jquery in HTML and take a response to other Html Page

From Dev

Using return false is stopping my AJAX call from executing, removing it fixes it but then the page refreshes

Related Related

  1. 1

    Ajax return full html page

  2. 2

    How to remove a specific tag from the entire html page using jsoup

  3. 3

    Unable to call Page Method using jQuery ajax

  4. 4

    Using ajax to call php and return multiple variables?

  5. 5

    How can call a page on submit using ajax?

  6. 6

    Need Help to load a html page using jquery

  7. 7

    Jquery Ajax call doesn't hit the action method/returns entire HTML page

  8. 8

    Need to redirect php page to html using htaccess

  9. 9

    Wordpress ajax call returns entire html page

  10. 10

    I need part of the page to be changed dynamically with ajax

  11. 11

    Ajax call return whole page instead of replacing a div tag

  12. 12

    Return html form field on AJAX call

  13. 13

    jQuery ajax call only from HTML page

  14. 14

    Return view after using ajax call

  15. 15

    How to return PHP response to HTML page using AJAX

  16. 16

    I have a piece of html/javascript that need to be opened in a new page, but I'm using Wix.com

  17. 17

    AJAX request returns entire HTML page instead of just the data I wanted it to echo

  18. 18

    How to remove a specific tag from the entire html page using jsoup

  19. 19

    Unable to call Page Method using jQuery ajax

  20. 20

    Populate html dropdown list using Ajax function call during page load

  21. 21

    Programming scrollbar (like volume control) in html page that produces call on update using php/javasctipt/ajax technologies

  22. 22

    I need jqgrid to refresh the entire page, not just the grid

  23. 23

    Jquery Ajax call doesn't hit the action method/returns entire HTML page

  24. 24

    I need part of the page to be changed dynamically with ajax

  25. 25

    Return view after using ajax call

  26. 26

    using Python, Flask and Ajax, how can I parse a response from an ajax call and print as HTML?

  27. 27

    How can I replace the entire HTML of a page, or its body content, via an AJAX call's success callback?

  28. 28

    Ajax Call using Jquery in HTML and take a response to other Html Page

  29. 29

    Using return false is stopping my AJAX call from executing, removing it fixes it but then the page refreshes

HotTag

Archive