template tag in a php echo – how???
-
I’m trying to get this working… but all in comes up with is the url…
http://xyz.com.au/wordpress/wp-content/uploads/venue.jpgI want…
http://xyz.com.au/wordpress/wp-content/uploads/venue64.jpg where 64 is the post ID<?php if ( in_category(17) || in_category (5) ) { echo '<a href="http://xyz.com.au/wordpress/wp-content/uploads/venue'.the_ID().'.jpg"><img class="alignright size-medium" src="http://xyz.com.au/wordpress/wp-content/uploads/venue'.the_ID().'.jpg" width="300px" title="'.the_ID().'" ></a>'; } else { echo '<p>nothing here</p>'; } ?>
The topic ‘template tag in a php echo – how???’ is closed to new replies.