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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T06:15:59+00:00 2026-06-10T06:15:59+00:00

I am trying to create an addon that turns all textareas on certain pages

  • 0

I am trying to create an addon that turns all textareas on certain pages into WYSIWYG HTML editors. I tried using PageMod by calling the NicEdit library and then running a content script with the code to turn all textareas into NicEdit editors. Here is the code I am trying to use:

main.js:

// Import the APIs
var pageMod = require("page-mod");
var self = require("self");

// Create a page mod
// It will run a script whenever a URL is loaded
pageMod.PageMod({
  include: "*",
  contentScriptFile: [self.data.url("nicEdit-latest.js"),
                      self.data.url("pagedit.js")]
});

pagedit.js

bkLib.onDomLoaded(nicEditors.allTextAreas);

And then NicEdit-latest.js is just the NicEdit lirbrary.

I saved and installed the addon and tried to load W3Schools’ demo on textareas, but the textarea still looked like a normal textarea.

  • 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-10T06:16:00+00:00Added an answer on June 10, 2026 at 6:16 am

    OK, I figured it out. The content scripts were firing at the wrong time. I fixed it by adding

         contentScriptWhen: ‘start’,

    between the include and the ContentScriptFile.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using openerp 6.1.1 and trying to create an applicant from thunderbird addon.
I am trying to create an add-in by using the article below http://blogs.microsoft.co.il/blogs/shair/archive/2008/07/28/how-to-create-sql-server-management-studio-addin.aspx I
I'm trying create a bot which automatically likes Facebook posts. Using Mechanize I can
Ok so I am trying create a login script, here I am using PHP5
I'm trying to create a program in C# that lists the content of a
I'm trying to create an xpi package for a firefox addon through cfx tool.
I'm trying to create a conditional overlay for firefox's new addon manager in minefield
I'm trying to create an Outlook 2010 addin that adds a new tab to
I need to create a simple IE addon, and trying to figure out how
I am trying create a WCF service that leverages the WPF MediaPlayer on the

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.