Using get_template_directory_uri()
or get_stylesheet_directory_uri()
you can retrieve the url to your themes folder, and after that you just need to specify the path starting from there. Your code should look like this:
<source src="https://wordpress.stackexchange.com/questions/256580/<?php echo get_template_directory_uri() ."/assets/videos/videobg.mp4'; ?>" type="video/mp4">
Related Posts:
- 404 Error while accessing the font files
- Random 404 error on WP
- Theme javascript/css 404
- 404 not working, going to homepage; how to fix?
- Theme making direct ajax calls to theme folder
- How to Link External jQuery/Javascript files with WordPress
- Am I allowed to license my WordPress theme under the aGPL
- Best way to include Bootstrap in WordPress
- Best practices for a Style/CSS based theme options page?
- How to license my commercial WordPress theme? [closed]
- How to Use WordPress as Static CMS Without Blog Posts
- How do I create my own admin button and theme settings page?
- How to set two different themes on one WordPress? (Desktop vs. Mobile)
- How can I add a set featured image function to a theme that doesn’t already have it built in?
- Jquery in Child Theme
- Changing the visible url path to css & js files
- How to display date such “x ago”
- How to use same theme template for multiple taxonomy terms?
- FTP Username and password wrong while installing theme
- WP Video media player not loading correct CSS after AJAX load
- Which is the most well coded and semantically correct naked/blank WordPress theme (based on WordPress coding standards)?
- How do you install a .MO (language file) to use as part of a theme?
- Question about the way that wp_register_script works
- Specific theme for non logged in users
- Cannot find the code for “Edit This” link in posts in a specific theme
- How to change the contact info at the bottom of my theme [closed]
- How to get the post-ID in my plugin?
- Customize “Continue Reading” text [closed]
- WordPress not displaying themes in the wp-content/themes folder
- Recommended Themes for a Developer-related Topics Blog?
- How to create child theme of already active and customized theme
- Console error, even if everything is working?
- How To Remove The “Delete” Theme Option In Dashboard
- How Do I Use A Custom Mobile Theme?
- How can I make a different theme be viewed for logged in users vs guests?
- Custom branding / theme specified by URL
- New custom theme option (text input) giving index error
- Upgrading from 2.9.4 to 3.0.x and with a custom theme
- CSS for triggering Avada toggles using an image or clickable element [closed]
- What is calling this parallax-slider.less file that is missing? [closed]
- Change WordPress Theme automatically for A/B test
- Theme option not saved if in wp_editor() and html decoded
- display comment form for specific post id
- Update wordpress theme without customization loss
- My new WordPress theme based on the TwentyEleven theme doesn’t display the front page OR the blog page
- How to add logo in Thematic
- How to create a new copy of a theme currently being used?
- Creating a job board using WordPress (for free)? [closed]
- How to transform a custom made static HTML website to a WordPress website [closed]
- Translate a site based on different themes
- Problems to disable the comments for my statics pages
- Template messed up on viewing posts
- Issue with theme mod options during domain migration
- FTP + Unable to locate WordPress content directory (wp-content)
- How to add custom JS file in WordPress Child theme with get_theme_file_uri
- How to access theme fonts using custom CSS style? [closed]
- Show hyperlinks only when user is loggedin
- I don’t know how to put a placeholder [closed]
- How to hide title on ‘highlights’ – Themify feature
- WordPress setup one database with two different website?
- Do all themes accommodate all features?
- How to reduce Header at the top of the page
- Custom fields not displaying on front end
- How can i set default pages to a word press theme? it shouldn’t be changed even if i install the theme in different host
- Change “published by”
- WordPress 2022 template, how to see the blocks added in post template on post edit?
- Two themes using a Multiple Themes plugin
- Broken theme, stylesheet is missing after uploading the right theme via FTP
- how to notify users about new theme updates?
- I cannot get an Advanced Custom Field code snippet to work – and ACF support say it should work
- Theme check warning about text domain
- dynamic image path within a javascript file
- WordPress thinks my custom theme is a theme in the public theme repository
- WP Customize API Checkbox change value
- Updating a theme
- Phone numbers showing same color as header [closed]
- Baskerville Theme – How to use the masonry grid layout on other pages
- Background image not showing up
- How to display post meta data in secure manner
- theme continuous deployment from bitbucket to windows azure
- Changing themes on locally hosted webpages
- Will this js code work in a page template?
- Showing wordpress theme demo at front end
- Create /archive page in WordPress Theme
- separate home page into separate pages
- Moving WordPress with Super Skeleton theme
- How can I allow a client to edit certain parts of a static site?
- A problem with functions.php file on my WordPress site
- To create a theme or use an existing one? [closed]
- Overwrite functions.php of a theme – What if the theme is updated?
- How to add/edit content Custom Content item in theme
- Is there a WordPress theme for twittstrap? [closed]
- change template with button
- How do I remove the dash (-) between my Site Title and Tagline?
- WordPress Theme redirects to the Index page – Theme customizer problem
- Obtaining the original unchanged Theme [closed]
- How to assign posts to different themes? [closed]
- Using AJAX to Update WordPress Theme
- Help with Divi logo not appearing for 10s
- How to clone a theme template from within WordPress? [closed]