• 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 [gallery]. 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 [gallery]‘s behavior and can’t find it by going through wp-admin’s guts.

    Thanks!

  • The topic ‘Gallery-Like Image for a Shortcode in Editor’ is closed to new replies.