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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T18:15:59+00:00 2026-05-24T18:15:59+00:00

Quick question about WordPress. I’ve been Googling all over the place and cannot find

  • 0

Quick question about WordPress. I’ve been Googling all over the place and cannot find an answer.

Basically I’m looking to replicate what happens when you add a gallery: have an image displayed as a stand in for the gallery shortcode . The shortcode’s visible when you go to edit HTML.

I’d like to exactly copy this effect: When a shortcode inserted into the editor I’d like for to to be rendered as an image.

Things I’ve Tried:

  • Inserting an element (image, div, I found an input is pretty unfuckwithable, etc) that’s wrapped by a shortcode (This works ok, not great. The short code’s still visible and WP will auto add paragraphs to the element to create space that users could, possibly, add content that’ll be eaten by the short code) –
  • Inerting the short code as a < !– –> comment (This also doesn’t work great, WP will occassionally eat it moving between Visual/HTML. The comments ALSO eat your content < !– [shortcode]–> placeholder < !–[/shortcode] –> = < !– rendered shortcode –>)

That’s the extent that I’ve thought of things. I cannot find a guide on how to do mimic the ‘s behavior and can’t find it by going through wp-admin’s guts.

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-24T18:16:00+00:00Added an answer on May 24, 2026 at 6:16 pm

    Alright, found the answer thanks to Dan’s hint. Here’s how to do it:

    First (as Dan suggested) take a look at how they add the Gallery plugin to Tiny MCE. There’s actually an uncompressed js file that will give you the overview you need, find it in:

    /wp-includes/js/tinymce/plugins/wpgallery/editor_plugin.dev.js

    This goes over the basics on adding this type of plugin to TinyMCE (more info here). To get WP to load the .js file with your TinyMCE plugin, see this helpful guide.

    Basically here’s the code:

    if ( get_user_option('rich_editing') == 'true') {
        add_filter("mce_external_plugins", "add_jolokia_tinymce_plugin");
    //Applying the filter if you're using the rich text editor
    }
    
    function add_jolokia_tinymce_plugin($plugin_array) {
        $plugin_array['example'] =  '/path/to/example.js';
        return $plugin_array;
    }
    

    Add this to a plugin or function.php in a theme And you’re good!

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

Sidebar

Related Questions

Quick question about Wordpress PHP: I am writing a theme and I want to
I have a quick question about jquery .. I want to find < a
Quick question about something I've ran into alot recently: So many times I'm looking
Folks, I had a quick question about Amazon EC2, I have been recently using
I got a quick question about running a directX application (C++) in a managed
I have a quick question about fetching results from a weakly typed cursor and
I've got a quick question about default values in PL/SQL functions in Oracle. Take
Just a quick question about ReadWriteLocks in Java (specifically the ReentrantReadWriteLock implementation) as I
Just a quick question about how parameters are passed in Java... ... if ((index
I just had a quick question about git - how backwards compatible are git

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.