i created a page content type, and put this code in it. and set the input style to php.why the image can't show. i test it on my localhost.
<img src="<?php echo $bath_path; ?>/images/1.jpg">
i created a page content type, and put this code in it. and set the input style to php.why the image can't show. i test it on my localhost.
<img src="<?php echo $bath_path; ?>/images/1.jpg">
Drupal way:
$path2file = base_path().'/images/1.jpg'; // If image located in {drupal root}/images. If image located in files directory, use file_directory_path() to get this path
print theme('image', $path_to_file, t('Image altername name'), t('Image title'));