Replies: 0
I have just updated WordPress after a long time.
I’ve been using a plugin -My Default Post Content– that allowed me to define a default code showed when I started a post. but, with the new editor, it doesn’t work.
to solve that, at theme functions they wrote me a code:
// ===================generating default post content =======================
add_filter( 'default_content', 'my_editor_content' );
function my_editor_content( $content ) {
$content = '<div><span class="bodytitle">Subtítulo</span></div>
IMAGEN
<p><span class="credit">créditos</span></p>
Cuerpo<!--more-->
_
GALERÍA';
return $content;
}
and using another plugin –Classic Editor– it works. but Classic Editor does not use the more recent editor blocks editor of wordpress.
there what is shows by default is:

I should need something like that:
instead of:
<!– wp:gallery {«linkTo»:»none»} –>
<figure class=»wp-block-gallery columns-0 is-cropped»><ul class=»blocks-gallery-grid»></figure>
<!– /wp:gallery –>
this:
<div><span class=”bodytitle”>Subtítulo</span></div>
IMAGEN
<p><span class=”credit”>créditos</span></p>
Cuerpo<!–more–>
_
GALERÍA
is there a way to reach that?