How to give image source in wordpress page editor?

You can define constant in theme function file as:

if( !defined(THEME_IMG_PATH)){
   define( 'THEME_IMG_PATH', get_stylesheet_directory_uri() . '/site/images' );
  }

and then you can use img tag as

 <img src="https://wordpress.stackexchange.com/questions/252559/<?php echo THEME_IMG_PATH; ?>/footLogo.png" style="padding: 0px!important; color:white">

Leave a Comment