I disabled URL embed in Wordpress using the following code in functions.php:
function my_deregister_scripts(){
wp_dequeue_script( 'wp-embed' );
}
add_action( 'wp_footer', 'my_deregister_scripts' );
The embedded iframe is gone, but the link is still not showing. I only get the page title linked to that URL (and within a blockquote, I don't know why).
How can I simply post a link in Wordpress comments and have it show up as is:
Thanks!
I disabled URL embed in Wordpress using the following code in functions.php:
function my_deregister_scripts(){
wp_dequeue_script( 'wp-embed' );
}
add_action( 'wp_footer', 'my_deregister_scripts' );
The embedded iframe is gone, but the link is still not showing. I only get the page title linked to that URL (and within a blockquote, I don't know why).
How can I simply post a link in Wordpress comments and have it show up as is:
http://www.example.com
Thanks!
embed
oembed
Share
Improve this question
asked Feb 23, 2020 at 19:15
AlexAlex18111 silver badge99 bronze badges2
I'm not sure I understand, WordPress doesn't support OEmbed in comments out of the box. Something on your site perhaps a theme or a plugin has added oembeds to your comments. Normal WordPress does not support embeds in comments. You should look at your plugins and themes and identify which one is adding this behaviour to your site
– Tom J Nowell
♦CommentedFeb 23, 2020 at 20:44
Does this answer your question? Remove link preview in discussion dashboard
– Jani Uusitalo
CommentedJan 3, 2021 at 12:56
Add a comment
|
1 Answer
1
Reset to default
0
(Note that this answer deals with URL previewing in the Admin, Comments area. URLs are not 'previewed' in what the visitor sees in your posts' comments.)
If you inspect the source of the Comments page (in Admin, Comment area, where a link will be previewed if you hover over it), you will see that the code is done by the Akismet plugin, which add this CSS (in akismet.css line 42):
I see this default display of links in the Admin, Comments area as a possible malware problem. But when I asked them about it (last year), there was no indication they saw it as a problem. I still don't like it, especially since Akismet is a very common plugin on WP sites.