• Resolved iamnikki

    (@iamnikki)


    I am using colormag pro. After the latest update to V3.1.6, it is conflicting with Secondary title (i am suspecting). the main & secondary title are showing as common main title (one line together) and showing all HTML H1 tags, color ###, span> etc means all html attributes only on post title appearing on category pages. If i open single post, it is working ok there. The issue is displayed only on category page.

    Could you please advice?

Viewing 1 replies (of 1 total)
  • Plugin Author thaikolja

    (@thaikolja)

    Hi @iamnikki,

    Please excuse the late reply.

    I’ve just had a look at the theme you mentioned and noticed that it escapes the HTML inside the code. This means that the HTML added with Secondary Title won’t render.

    Unfortunately, COLORMAG doesn’t provide a filter hook for this. The only way to bypass this is by modifying the file wp-content/themes/colormag-pro/content.php. Around lime 88 you’ll find this section:

    <header class="entry-header">
    	<h2 class="entry-title"<?php echo colormag_schema_markup( 'entry_title' ); // phpcs:ignore WordPress.XSS.EscapeOutput.OutputNotEscaped ?>>
    		<a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
    			<?php echo colormag_get_the_title( get_the_title() ); ?>
    		</a>
    	</h2>
    </header>

    Replace this line:

    <?php echo esc_html( colormag_get_the_title( get_the_title() ) ); ?>

    With this:

    <?php echo colormag_get_the_title( get_the_title() ); ?>

    To avoid losing this change when updating the theme in the future, it’s best to do this in your child theme.

    If you need any more assistance, please let me know.

    • This reply was modified 3 years, 3 months ago by thaikolja.
Viewing 1 replies (of 1 total)
  • The topic ‘post title shows html tags and combining both titles together in a line’ is closed to new replies.