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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T13:57:31+00:00 2026-05-19T13:57:31+00:00

I have a TinyMCE editor that I need to add a tag to in

  • 0

I have a TinyMCE editor that I need to add a tag to in its doncument’s head. I have this working by adding

$(tinyMCE.activeEditor.getDoc()).children().find('head').append('<base href=\"TheURL\">');

to a init_instance_callback function. When I inspect the DOM, I see that it was added properly. Any images I add to the editor now use the new base information. The issue is any existing items that were loaded into the editor do not use it as they already “errored” out before the base tag was added.

Any ideas how to add the tag before the document is loaded, or how to reload the document with the base tag in place?

Thanks,

  • 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-19T13:57:32+00:00Added an answer on May 19, 2026 at 1:57 pm

    Try to use the onBeforeSetContent event. This way the base-tag gets added before the editor gets filled with the initial content. You may want to set a global variable to true if the base-tag has been added in order to check for it and to add it only once and not on every onBeforeSetContent event.

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

Sidebar

Related Questions

I have a problem with FCKEditor and TinyMCE. I need a WYSIWYG editor that
I have a tinyMCE plugin (for the post/page editor) that I am loading from
I recently started developing websites on wordpress. I have this problem with tinymce editor.
I have a TinyMCE editor in my page. I would like to add/remove buttons/plugins
I have a blog section on my site that has the TinyMce editor. I
I have a page when user can add 0 to N TinyMCE editors that
AFAIK, TinyMCE is supposed to be self-sufficient XSS-wise, as its editor prevents anything that
I have problem with TinyMCE editor. I have form with few text fields and
I have a great concern in deploying the TinyMCE editor on a website. Looking
I am building an auto-save feature for my TinyMCE editor. With jQuery, I have

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.