Title: Can&#8217;t Embed Custom Code
Last modified: December 21, 2020

---

# Can’t Embed Custom Code

 *  [ikhnetworks](https://wordpress.org/support/users/ikhnetworks/)
 * (@ikhnetworks)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/cant-embed-custom-code/)
 * Ever since I updated to WordPress 5.6 I can’t embed my video player so I restored
   to an iframe which isn’t good and very unwelcomed.
 * I have included [a link to the issue](https://imgur.com/a/x2IY5xg) seen here
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fcant-embed-custom-code%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Moderator [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * (@bcworkz)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/cant-embed-custom-code/#post-13824096)
 * You appear to be trying to place `<link>` tags into a custom HTML block. That’s
   not really allowed even if you got away with it earlier. `<link>` tags belong
   in the page’s `<head>` section. To get them there, the referenced files should
   be enqueued with `wp_enqueue_style()` with code added to functions.php. While
   you’re at it, the `<script>` tags aren’t reliable in HTML blocks either, though
   technically allowed per HTML standards. It’d be better if the referenced files
   were also enqueued, this time with `wp_enqueue_script()`
 *  Thread Starter [ikhnetworks](https://wordpress.org/support/users/ikhnetworks/)
 * (@ikhnetworks)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/cant-embed-custom-code/#post-13824341)
 * Where and how to edit this file.
 *  Moderator [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * (@bcworkz)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/cant-embed-custom-code/#post-13828297)
 * [https://developer.wordpress.org/reference/functions/wp_enqueue_style/](https://developer.wordpress.org/reference/functions/wp_enqueue_style/)
   
   In particular, review the More Information > Notes section here: [https://developer.wordpress.org/reference/functions/wp_enqueue_script/](https://developer.wordpress.org/reference/functions/wp_enqueue_script/)
   There are useful examples in the user notes sections near the end of each page.
 * The code can go in functions.php of your theme, or in a custom plugin. Instead
   of altering your theme, it’s better to create a [child theme](https://developer.wordpress.org/themes/advanced-topics/child-themes/).
   TBH, if you will not be modifying any templates, a [custom plugin](https://developer.wordpress.org/plugins/plugin-basics/)
   is easier to create.
 * To create a child or plugin, you need FTP or your hosting file manager because
   new files need to be uploaded. You can edit your existing theme with the theme
   editor. It’s recommended you switch to a different theme before changing anything
   in your normal theme. If there are any errors in the changes, the theme will 
   not reactivate. Errors made in an active theme could lock you out of WP, requiring
   FTP to go in and fix the errant code.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Can’t Embed Custom Code’ is closed to new replies.

## Tags

 * [embed issues](https://wordpress.org/support/topic-tag/embed-issues/)
 * [WordPress 5.6.](https://wordpress.org/support/topic-tag/wordpress-5-6/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 2 participants
 * Last reply from: [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * Last activity: [5 years, 4 months ago](https://wordpress.org/support/topic/cant-embed-custom-code/#post-13828297)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
