News Manager Addons 0.4 beta available.
Updated to support the post images feature in News Manager 2.5 (currently in beta)
New tokens are:
{{ post_image_url }} - full URL of the post thumbnail/image
{{ post_image }} - html code for the thumbnail/image URL (<img src="...)
If you want to override the default settings for displaying post images, you can change it (before using nm_custom_display, etc.) with function nm_set_custom_image($width=null, $height=null, $crop=null, $default=null).
Example:
Cropped 200 (width) x 150 (height) images:
No cropping + default image in data/uploads (for posts that don't have one):
(last parameter could also be the full image URL, 'http://....')
Updated to support the post images feature in News Manager 2.5 (currently in beta)
New tokens are:
{{ post_image_url }} - full URL of the post thumbnail/image
{{ post_image }} - html code for the thumbnail/image URL (<img src="...)
If you want to override the default settings for displaying post images, you can change it (before using nm_custom_display, etc.) with function nm_set_custom_image($width=null, $height=null, $crop=null, $default=null).
Example:
Code:
<?php nm_set_custom_image(100, 100); ?>
<?php nm_custom_display_recent('
<div class="my_recent_post">
<h4><a href="{{ post_link }}">{{ post_title }}</a></h4>
<div class="my_image">{{ post_image }}</div>
<span class="my_excerpt">{{ post_excerpt }}</span>
</div>
'); ?>
Cropped 200 (width) x 150 (height) images:
Code:
nm_set_custom_image(200, 150, 1);
No cropping + default image in data/uploads (for posts that don't have one):
Code:
nm_set_custom_image(200, 150, 1, 'image1.jpg');