Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to remove Author Tag from being visible in Discord's previews?

When sharing a post to Discord, the preview Discord generates shows the author name and URL. We removed all information about the author but it didn't stop the author tag from showing.

Image here

like image 620
Harut Avatar asked Mar 06 '19 08:03

Harut


People also ask

How do I stop Discord from showing preview?

At the bottom-right of the page, tap your profile icon to access User Settings. Scroll down and select Text & Images under the App Settings section. Near the bottom of the page, disable the link preview option. You can also disable previews for images and videos to save some mobile data.

How do I remove the author from a Wordpress theme?

Once you install and activate the plugin, go to All in One SEO » Search Appearance in your dashboard and then click the 'Archives' tab. Now you can see the author archive settings. You can toggle Author Archives switch and disable author archives on your site.

How do I share a youtube link on Discord without preview?

Step 2: Under the “App Settings” section, tap “Text & Images.” Step 3: Under the “Link Preview” section, tap the toggle to the right of “Show website preview info from links pasted into chat” to stop Discord from showing website previews as you use the app.

How do you remove a hyperlink in Discord?

Pro Tip: If you want to cancel an embed for one specific link, you can wrap the link in '< >' tags.


1 Answers

That’s done via oEmbed. Add below code in your functions.php file

add_filter( 'oembed_response_data', 'disable_embeds_filter_oembed_response_data_' );
function disable_embeds_filter_oembed_response_data_( $data ) {
    unset($data['author_url']);
    unset($data['author_name']);
    return $data;
}

**disorc may have stored the response in cache so create new post or page and test that **

like image 75
hrak Avatar answered Apr 28 '23 10:04

hrak