Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7774787
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T17:27:54+00:00 2026-06-01T17:27:54+00:00

How embarrassing. I had this working on a previous project, but now i am

  • 0

How embarrassing. I had this working on a previous project, but now i am unable to get the simplest examples
of load and $.get to work right.

My simple little web page is shown below. When i use firebug i can see that http requests are being made
(in the case below to cnn.com, i also tried google.) But firebug shows these requests in red for some reason.

The div with id ‘container’ does not get updated. and i never see the callback indicating ‘here is the data’.

Must be something real simple and dumb..but after tinkering for an hour i’m ready to cry for help.

any advice much appreciated. Thanks !

        <!DOCTYPE html>
        <html lang="en">
        <head>

         <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>

          <script type="text/javascript">
            $(document).ready(function () {

              alert('in ready handler');
              $('#container').load('http://www.cnn.com/');
              alert('after container load');
              $.get(
                    'http://www.cnn.com/', 
                    function(data) {  
                        alert('here is the data' + data); 
                    } 
              );
              alert('after get was called');
            });

          </script>
        </head>

        <body>
        the container:
          <div id="container"></div>
        </body>
        </html>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T17:27:55+00:00Added an answer on June 1, 2026 at 5:27 pm

    This is a cross domain protection mechanism.

    The best option is to have a simple php file on your server which requests the content from the remote site and send it back e.g.

    AJAX.php

    $ echo file_get_contents('http://www.cnn.com/');
    

    You JS

    $ ('#container').load('ajax.php');
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know this is embarrassing easy but I cannot get this to work right
This is kind of embarrassing but I cannot for some reason get his CSS
This is embarrassing, but here goes. Here's the page that I'm working on: www.mchenry.edu/administration/BoardSchedule.asp
Well, this is embarrassing. I want to get into Flex development but I'm having
All right this is kind of embarrassing, but I am not sure what is
It's little embarrassing to ask this question. But I can't figure out a way
now this is embarrassing. I'm writing quick script and I can't figure out why
This is an embarrassing question, but even the well-written documentation provided with boost.interprocess hasn't
It is quiet embarrassing but I just don't get it. How should I browse
**Have it working now. I forgot to populate the Array List. How embarrassing. I'm

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.