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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T13:27:15+00:00 2026-06-07T13:27:15+00:00

I am developing chrome extension, it is a simple extension which call background.js file

  • 0

I am developing chrome extension, it is a simple extension which call background.js file to do simple job. In background.js i want to include jquery.js file to call ajax function. But i can’t find anyway to include jquery.js in background.js. is it possiable to do that?

you know, extension call background.js and it does not call php or html file which include background.js so i can’t use anything get involved in php or html

Thanks in advance….

  • 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-07T13:27:17+00:00Added an answer on June 7, 2026 at 1:27 pm

    Here ya go:

    var jQueryElement=document.createElement('script');
    jQueryElement.type = 'text/javascript';
    jQueryElement.src = 'https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js';
    document.getElementsByTagName('head')[0].appendChild(jQueryElement);
    

    You will have to put everything in the onload event handler, otherwise, the rest of the JavaScript will continue running even if jQuery hasn’t loaded yet.

    var jQueryElement=document.createElement('script');
    jQueryElement.type = 'text/javascript';
    jQueryElement.onload = function () {
        alert('jQuery loaded');
    };
    jQueryElement.src = 'https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js';
    document.getElementsByTagName('head')[0].appendChild(jQueryElement);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm developing a Chrome extension for a client which want me to embed a
I want to develop a simple Chrome extension in C++, using NPAPI, which does
I'm currently developing a simple javascript extension for Chrome. The problem is simple but
I m developing a chrome extension and i want to know that from which
I am developing a simple page action extension in google chrome and it has
I am developing a chrome extension, and I want to be able to control
we are in process of developing google chrome extension, in which we need to
I'm developing a Google Chrome extension, which produces an error I can't fix. My
At the moment I am developing a Google Chrome Extension in which I have
In a Chrome Extension I am developing, I want to access a data structure

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.