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 284881
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T05:29:46+00:00 2026-05-12T05:29:46+00:00

I need to get content from an external page and pass it as an

  • 0

I need to get content from an external page and pass it as an argument to a function. I have looked into the url() method in the JQuery documentation but it seems it’s only possible to use it to insert external content into div or some other HTML element.

Basically what I need to do is:

// I need to insert external page's content into the cont variable, how to do that?
var cont;
// so I can pass it to the bt() function (it's a tooltip plugin)
$('.class').bt(cont, {
    fill: '#2a4d6b',
    cssStyles: {color: 'orange', fontWeight: 'bold', width: 'auto'}
});

Can anyone tell me if something like that is possible?

  • 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-05-12T05:29:46+00:00Added an answer on May 12, 2026 at 5:29 am

    You want to use .get (http://docs.jquery.com/Ajax/jQuery.get#urldatacallbacktype) insetad of load. It takes a callback function as an argument. The below will load a link and display it in an alert.

    $.get('http://your.website.com/page.html', 
      function (data) {  alert(data) } );
    

    your example rewritten:

    $.get('http://your.website.com/page.html', 
          function (data) {  setClass(data); });
    
    function setClass(cont) {
        $('.class').bt(cont, {
            fill: '#2a4d6b',
            cssStyles: {color: 'orange', fontWeight: 'bold', width: 'auto'}  
        });
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need a method to get the data from an external editor. def _get_content():
This is the code on the script, i need to get the content from
I'm using PHP to get content from an external website. I want to know
Possible Duplicate: Extracting the content of an element from an external page Is there
I need to get the spring application context from a non bean object. In
How can I get content of a DIV using regular expression. What I need
I need a way to get a ( content ) MovieClip within a (
I need to get the Portuguese text content out of an Excel file and
In php I need to get the contents of a url (source) search for
I need get all items these have no categories int? categoryId = null; var

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.