admin

Website Tutorial

How to Only Get the WordPress Featured Image URL

To get the URL of the featured image (also known as the post thumbnail) in WordPress, you can use the get_the_post_thumbnail_url() function. This function retrieves the URL of the featured image for a given post. Here’s how you can use...
Website Tutorial

WordPress functions.php-add CSS styles and JS scripts

Although our theme has a style.css file, it is not used yet. Let’s enqueue it now. Add the following code to functions.php, so that the styles added in style.css will be applied to the theme’s styles: function my_custom_theme_enqueue() {wp_enqueue_style( ‘my-custom-theme’,...
Email Marketing

Email Marketing-How to add Google Analytics to emails?

Adding Google Analytics tracking to emails involves a slightly different approach compared to tracking website visits. Here’s a step-by-step guide on how to add Google Analytics tracking to emails: Step 1: Get Your Google Analytics Tracking ID Sign in to...
Website Tutorial

WordPress functions.php-Add Featured Images

As with sidebars and navigation menus, we can’t just output featured images in our theme and expect them to work, we must first tell WordPress that we support the feature. In functions.php add: add_theme_support( ‘post-thumbnails’ ); Now we can add_post_thumbnail();...
Website Tutorial

WordPress functions.php-Add a Sidebar

Adding a Sidebar Our theme also doesn’t have a sidebar (widget area), let’s fix that now. First, we need to register the sidebar in functions.php: function my_custom_theme_sidebar() {register_sidebar( array( ‘name’ => __( ‘Primary Sidebar’, ‘my-custom-theme’ ), ‘id’ => ‘sidebar-1’,) );...