2019-01-09, 14:32:46
Dear GS-friends,
thanks to some examples from Oleg I figured out how to display news in custom layout with php code directly.
Example:
For a newer project I urgently need to output the "Tags" of the news entries, too.
(The goal is to add the "Tag" as a CSS-Class to the entries in order to enable a simple filtering function with javascript and CSS)
I tried {{ post_tag }} , but it didn't seem to work.
Is there any way to output the News-"Tags" with php?
Thanks for all your great coding and help!
thanks to some examples from Oleg I figured out how to display news in custom layout with php code directly.
Example:
Code:
<div class="posts">
<?php nm_set_custom_image(160,160,1); ?>
<?php nm_set_custom_excerpt(200); ?>
<?php nm_set_custom_maxposts(8); ?>
<?php nm_custom_display_random('
<article>
<h4><a href="{{ post_link }}">{{ post_title }}</a></h4>
<p class="nm_post_date">{{ post_date }}</p>
<a href="{{ post_link }}">{{ post_image }}</a>
<div class="my_excerpt">{{ post_excerpt }}</div>
</article>
'); ?>
</div>
For a newer project I urgently need to output the "Tags" of the news entries, too.
(The goal is to add the "Tag" as a CSS-Class to the entries in order to enable a simple filtering function with javascript and CSS)
I tried {{ post_tag }} , but it didn't seem to work.
Is there any way to output the News-"Tags" with php?
Thanks for all your great coding and help!