Do An Duy
asked 6 years ago

Hi,

I can’t strike through text when posting answers using DWQA.

The strikethroughs appear normally when I write the answer but after I post it, they disappear.

What should I do?

Thank you.

2 Answers
Kevin
answered 6 years ago

Hi,

Please provide me some screenshot about your issue then I will have you solve it.

Do An Duy
replied 6 years ago

Thank you for your reply, Kevin.

I want to strikethrough text like this (highlight text and press Ctrl + Shift + d)
http://i.imgur.com/eNkzHSg.png

Or use the del tag in the HTML editor:
http://i.imgur.com/g2aSeXf.png

But when I post the answer, the strikethough lines disappear:
http://i.imgur.com/PkQNal4.png

Kevin
answered 6 years ago

Hi,

You can add the code below to wp-content/themes/your-theme-folder/functions.php

add_filter( 'dwqa_filter_kses', 'dwqa_theme_post_kses_filter' );
function dwqa_theme_post_kses_filter( $args ) {
	$args['del'] = array();

	return $args;
}

Do An Duy
replied 6 years ago

That worked perfectly. Thanks a lot Kevin!

Kevin
replied 6 years ago

You’re welcome 🙂

Powered by DW Question & Answer Pro